Skip to content
Last updated

B2B API Profile Management Guide

Overview

Profile Management lets you:

  • Create a profile for each primary and secondary cardholders associated with an account.
  • All calls to the endpoint must have a valid JWT Token.

Create profiles

Only primary and secondary cardholders can have a profile. If a profile already exists for a cardholder the new account will be linked to their existing profile.

Standard profile creation

An email will be sent to cardholder to provide / update their password

API Call Example:

curl -i -X POST \
  https://api.raipartners.com/b2b/portal/profile \
  -H 'API-Version: 1.0.0' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "opa": "1234567890123456",
    "primaryCardholder": {
      "name": {
        "first": "John",
        "last": "Smith",
        "middle": "James"
      },
      "dob": "2000-01-31",
      "ssn": "123456789",
      "cardNumber": "1234567890123456",
      "communications": {
        "mobilePhone": {
          "number": "1234567890",
          "verified": true
        },
        "email": {
          "address": "myemail@email.com",
          "verified": true
        }
      },
      "address": {
        "line1": "1 Main St",
        "line2": "Apt 35",
        "city": "Dallas",
        "state": "TX",
        "zipCode": "75000"
      },
      "income": {
        "amount": 10000,
        "source": "Employment",
        "frequency": "Yearly"
      }
    },
    "secondaryCardholder": {
      "name": {
        "first": "John",
        "last": "Smith",
        "middle": "James"
      },
      "dob": "2000-01-31",
      "ssn": "123456789",
      "cardNumber": "1234567890123456",
      "communications": {
        "mobilePhone": {
          "number": "1234567890",
          "verified": true
        },
        "email": {
          "address": "myemail@email.com",
          "verified": true
        }
      },
      "address": {
        "line1": "1 Main St",
        "line2": "Apt 35",
        "city": "Dallas",
        "state": "TX",
        "zipCode": "75000"
      },
      "income": {
        "amount": 10000,
        "source": "Employment",
        "frequency": "Yearly"
      }
    },
    "authorizedUsers": [
      {
        "name": {
          "first": "John",
          "last": "Smith",
          "middle": "James"
        },
        "dob": "2000-01-31",
        "ssn": "123456789",
        "cardNumber": "1234567890123456",
        "communications": {
          "mobilePhone": {
            "number": "1234567890",
            "verified": true
          },
          "email": {
            "address": "myemail@email.com",
            "verified": true
          }
        },
        "address": {
          "line1": "1 Main St",
          "line2": "Apt 35",
          "city": "Dallas",
          "state": "TX",
          "zipCode": "75000"
        },
        "income": {
          "amount": 10000,
          "source": "Employment",
          "frequency": "Yearly"
        }
      }
    ]
  }'

API Call Response: This endpoint returns a 204 status upon success (no content is returned)

Response
No content

A magic-link allowing for the primary cardholder to to login instantly is returned as a payload. If a secondary cardholder exists, a magic-link will be emailed to that secondary cardholder.

API Call Example:

curl -i -X POST \
  https://api.raipartners.com/b2b/portal/profile/magic-link \
  -H 'API-Version: 1.0.0' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "opa": "1234567890123456",
    "primaryCardholder": {
      "name": {
        "first": "John",
        "last": "Smith",
        "middle": "James"
      },
      "dob": "2000-01-31",
      "ssn": "123456789",
      "cardNumber": "1234567890123456",
      "communications": {
        "mobilePhone": {
          "number": "1234567890",
          "verified": true
        },
        "email": {
          "address": "myemail@email.com",
          "verified": true
        }
      },
      "address": {
        "line1": "1 Main St",
        "line2": "Apt 35",
        "city": "Dallas",
        "state": "TX",
        "zipCode": "75000"
      },
      "income": {
        "amount": 10000,
        "source": "Employment",
        "frequency": "Yearly"
      }
    },
    "secondaryCardholder": {
      "name": {
        "first": "John",
        "last": "Smith",
        "middle": "James"
      },
      "dob": "2000-01-31",
      "ssn": "123456789",
      "cardNumber": "1234567890123456",
      "communications": {
        "mobilePhone": {
          "number": "1234567890",
          "verified": true
        },
        "email": {
          "address": "myemail@email.com",
          "verified": true
        }
      },
      "address": {
        "line1": "1 Main St",
        "line2": "Apt 35",
        "city": "Dallas",
        "state": "TX",
        "zipCode": "75000"
      },
      "income": {
        "amount": 10000,
        "source": "Employment",
        "frequency": "Yearly"
      }
    },
    "authorizedUsers": [
      {
        "name": {
          "first": "John",
          "last": "Smith",
          "middle": "James"
        },
        "dob": "2000-01-31",
        "ssn": "123456789",
        "cardNumber": "1234567890123456",
        "communications": {
          "mobilePhone": {
            "number": "1234567890",
            "verified": true
          },
          "email": {
            "address": "myemail@email.com",
            "verified": true
          }
        },
        "address": {
          "line1": "1 Main St",
          "line2": "Apt 35",
          "city": "Dallas",
          "state": "TX",
          "zipCode": "75000"
        },
        "income": {
          "amount": 10000,
          "source": "Employment",
          "frequency": "Yearly"
        }
      }
    ]
  }'

API Call Response: This endpoint returns a payload containing a magic-link

Response
{ "magicLink": "string" }