Referred Client(s)

This action retrieves information about end-user(s) you've referred to the White Swan.

The IDs returned by this action can be used in other information calls to retrieve further information about Plan Request(s) or Personal Plan(s) associated with a given client.

API Method:

Fetch Client(s)

POST https://app.whiteswan.io/api/1.1/wf/client

Returns information about referred end-users associated with your White Swan account.

Headers

NameTypeDescription

Authorization*

String

Bearer <YOUR API KEY>

Content-Type*

String

application/json

Accept*

String

application/json

user-agent*

String

<YOUR APP>

Request Body

NameTypeDescription

JSON Body*

Object

See specification below

Sample Body Payload
{
"client_email": "jane@gmail.com"
}

Please note that the sample body payload above contains all possible parameters for your reference. In an actual call, you don't need to use all (or any) parameters.

Code Examples - Making the API Call:

curl -X POST "https://app.whiteswan.io/api/1.1/wf/client" \
     -H "Authorization: Bearer <YOUR API KEY>" \
     -H "Content-Type: application/json" \
     -H "Accept: application/json" \
     -H "User-Agent: <YOUR APP>" \
     -d '{
               "client_email": "jane@gmail.com"
          }'

Code examples are available in cURL, Python, Javascript, Java, PHP, Ruby, and Go, but can be constructed for other languages and tools. Some code examples include dependencies that may need to be installed in your codebase to ensure functionality. Remember to replace any values in the code that looks like <VALUE> and to adapt the parameter values passed.


Body Parameters Specification:

Field LabelField KeyField TypeExample ValueDescription

Client Email

client_email

Text

john@doe.com

This input can optionally be used to get information about a specific client.


Sample Return Payload
[{
"name": "Alice Johnson",
"email": "alice.johnson@example.com",
"referrer": "Alex Johnson",
"associated_request_ids": [
          "1234567890x0987654321"
],
"associated_plan_ids": [
          "1234567890x1122334455"
]
}]

Returned Parameters Specification:

Field LabelField KeyExample ValueDescription

Referred Client Name

name

Alice Johnson

The name of the referred client.

Referred Client Email

email

alice.johnson@example.com

The email address of the referred client.

Account User Referring Client

referrer

Alex Johnson

The name of the user on your White Swan account who referred the client.

Referred Client Associated Plan Request IDs

associated_request_ids

1234567890x0987654321

The ID of the plan request(s) associated with the referred client.

Referred Client Associated Personal Plan IDs

associated_plan_ids

1234567890x1122334455

The ID of the personal plan(s) associated with the referred client.

Last updated