Get Sandbox Access

Paybase Developer Centre

OverviewAPI GuidesGetting StartedRecipesGig Economy PlatformsSharing Economy PlatformsMarketplacesBlockchain BusinessesEscrowRolesRulesDue DiligenceCustomersAccountsBank AccountsCardsTransactionsIntroductionInboundGetting money into the systemTransaction ReferenceAccount ReferenceInternalOutboundEscrowSplit PaymentsRefundsStrong Customer Authentication3D Secure AuthenticationIntroductionCreate a cardCreate a transactionDocument UploadStatementsWebhooksErrorsPQLAPI ReferenceAccountCreate an accountRetrieve an accountTransition account statusList all accountsAnnotate an accountDelete annotation from an accountTag an accountDelete tag from an accountBank AccountCreate a bank accountRetrieve a bank accountUpdate a bank accountTransition bank account statusList all bank accountsAnnotate a bank accountDelete annotation from a bank accountTag a bank accountDelete tag from a bank accountCardCreate a cardRetrieve a cardUpdate a cardTransition card statusList all cardsAnnotate a cardDelete annotation from a cardTag a cardDelete tag from a cardCardholderCreate a cardholderRetrieve a cardholderUpdate a cardholderTransition cardholder statusList all cardholdersAnnotate a cardholderDelete annotation from a cardholderTag a cardholderDelete tag from a cardholderCreate an authentication tokenCheckCreate a checkCustomerIndividual CustomerCreate a customerRetrieve a customerUpdate a customerSole TraderCreate a customerRetrieve a customerUpdate a customerOrganisationCreate a CustomerRetrieve a CustomerUpdate a CustomerIncorporated BusinessCreate a customerRetrieve a customerUpdate a customerBusiness PersonAdd a business personRetrieve a business personUpdate a business personDelete a business personRetrieve a customerTransition state of a customerList all customersAnnotate a customerDelete annotation from a customerTag a customerRemove tag from a customerCreate an authentication tokenTouch a customerDocumentCreate a documentRetrieve a documentList Document TypesReferenceRetrieve a referenceStatementRetrieve a statementStatusRetrieve API statusTransactionCreate inbound transactionCreate internal transactionCreate outbound transactionRetrieve a transactionTransition transaction statusList all transactionsAnnotate a transactionDelete annotation from a transactionTag a transactionDelete tag from a transaction
API version: 7c99a7a

Update individual customerPATCH/v1/customer/individual/{id}

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
import { v1 } from '@paybase/client';

const client = v1('<- API Key ->', { sandbox: true });

const { accessToken } = await client.createCustomerAuthenticationToken({
  id: "customer/28958679-e8a8-47a8-967c-f979ae8509a2"
});

const result = await client.updateIndividualCustomer({
  id: "customer/28958679-e8a8-47a8-967c-f979ae8509a2",
  profile: {
    firstName: "John"
  },
  terms: {
    acceptedAt: "2019-03-07T15:24:27.697Z",
    revision: "1.0.0"
  }
}, { apiKey: accessToken });

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import json
import requests

requests.patch(
  "https://api-json.sandbox.paybase.io/v1/customer/individual/customer/28958679-e8a8-47a8-967c-f979ae8509a2Params: id",
  data = json.dumps({
    profile: {
      firstName: "John"
    },
    terms: {
      acceptedAt: "2019-03-07T15:24:27.697Z",
      revision: "1.0.0"
    }
  }),
  headers = {
    Content-Type: "application/json",
    X-Token: "<X-Token goes here>"
  }
).json()

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
$client = new \GuzzleHttp\Client();
$client->request(
  "patch",
  "https://api-json.sandbox.paybase.io/v1/customer/individual/customer/28958679-e8a8-47a8-967c-f979ae8509a2Params: id",
  [
    "body" => "{
      profile: {
        firstName: \"John\"
      },
      terms: {
        acceptedAt: \"2019-03-07T15:24:27.697Z\",
        revision: \"1.0.0\"
      }
    }",
    "headers" => [
      "Content-Type" => "application/json",
      "X-Token" => "<X-Token goes here>",
    ]
  ]
);

1
2
3
4
5
6
7
8
9
10
11
12
13
curl -X PATCH \
"https://api-json.sandbox.paybase.io/v1/customer/individual/customer/28958679-e8a8-47a8-967c-f979ae8509a2Params: id"  -H "Content-Type: application/json" \
  -H "X-Token: <X-Token goes here>" \
  -d '{
    profile: {
      firstName: "John"
    },
    terms: {
      acceptedAt: "2019-03-07T15:24:27.697Z",
      revision: "1.0.0"
    }
  }'

Request

FieldDescription
idURI Param
string

The unique identifier of the customer object.

Format

customer/_uuid_

e.g. customer/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

profile.emailoptional
string

The email address of the individual.

profile.phoneNumberoptional
string

The phone number of the individual including country code with a 00 or + prefix.

e.g 00447712345678 or +447712345678 for a UK phone number

profile.residentialAddress.flatNumberoptional
string

Flat number.

profile.residentialAddress.houseNameNumberoptional
string

House name or number. If the address has both, include both in the string.

profile.residentialAddress.streetoptional
string

Street name.

profile.residentialAddress.townCityoptional
string

Town or city.

profile.residentialAddress.regionoptional
string

Region/County/State/Province.

profile.residentialAddress.postalCodeoptional
string

Postal Code or ZIP.

profile.residentialAddress.countryISOrequired
string

Country code

Format

Two-letter ISO 3166-1 alpha-2 code.

e.g. GB

profile.firstNameoptional
string

The first name of the individual.

profile.lastNameoptional
string

The last name of the individual.

profile.doboptional
date

The date of the birth of the individual, in UTC.

Input Date Formats

profile.accountPurposeoptional
enum

A description of what the account will be used for.

enum

FREELANCE, GAMING, SALARY, INVESTMENT, OTHER, PURCHASE_GOODS_AND_SERVICES, SELL_GOODS_AND_SERVICES, SAVINGS, FRIENDS_AND_FAMILY,

terms.acceptedAtrequired
date

The timestamp in UTC at which the Terms were accepted.

terms.revisionrequired
string

Version name or number of the Terms that were accepted.

roleIdoptional
string

The unique identifier of the role. Can be found on your Console.

Format

role/_uuid_

e.g. role/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

roleSlugoptional
string

The unique slug for the role. Can be found on your Console.

Format

The default is the lower kebab-case of the role's name.

e.g. if the role name is Platform Seller, the slug will platform-seller.

Response

FieldDescription
id
string

The unique identifier of the customer object.

Format

customer/_uuid_

e.g. customer/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

createdAt
date

The timestamp in UTC at which the customer was created.

updatedAt
date

The timestamp in UTC at which the customer was last updated.

activeAt
date

The timestamp in UTC at which the customer was last considered active.

stateId
enum

The current state of the customer.

enum

  • PENDING - A customer in the PENDING state is present on the system, but is not yet ENABLED. Use this state when you wish to add a customer to the system, but don't want them to interact with it straight away.

  • ENABLED - The customer has been created and can start transacting if the required level of due diligence has been achieved.

  • DISABLED - The customer is temporarily disabled and cannot make any debit transactions from their account. e.g Withdrawals

  • LOCKED - The customer has been locked by Paybase and cannot transact until enabled again by Paybase.

  • CLOSING - The customer has been flagged for closing by Paybase and will be terminated within 90 days. Only withdrawals to an existing bankAaccount can be processed in this state.

  • TERMINATED - The customer has been terminated by Paybase and cannot interact with the system or trasition to another state.

annotations
object<string, string>

A hash map of key value pairs. Annotations allow you to supply information which is pertinent to your own system (e.g. Providing the ID of a customer on your system to link to their Paybase account). Annotations can also drive various Paybase rules.

tags
array<string>

An array of string values. Tags can be attached to objects in order to drive rules based logic either on Paybase or on your own system.

terms.acceptedAt
date

The timestamp in UTC at which the Terms were accepted.

terms.revision
string

Version name or number of the Terms that were accepted.

cddLevel
enum

The level of customer due diligence achieved by this customer.

enum

ZERO, ONE, TWO, THREE, FOUR, FIVE

Due diligence checks are performed asynchronously by our system. Therefore, at creation the cddLevel of a customer might be ZERO but will automatically increase as checks are processed by our system. In some instances, an automated check might fail and you will be required to provided additional information for the customer.

You can use to customer_cdd_level_changed webhook to get notified on changes in the cddLevel of a customer or the check_failed webhook for notifications on failed checks.

targetCDDLevel
enum

The targetCDDLevel for a customer depends on their role and is the level to which our system will attempt to verify a customer. The information required for each level differs and would have been provided to you at the time of onboarding.

enum

ZERO, ONE, TWO, THREE, FOUR, FIVE

roleId
string

The unique identifier of the role.

Format

role/_uuid_

e.g. role/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

profile.email
string

The email address of the individual.

Email address is one of the parameters we use to determine if an individual customer is unique.

profile.phoneNumber
string

The phone number of the individual including country code with a 00 or + prefix.

e.g 00447712345678 or +447712345678 for a UK phone number

profile.residentialAddress.flatNumber
string

Flat number.

profile.residentialAddress.houseNameNumber
string

House name or number. If the address has both, include both in the string.

profile.residentialAddress.street
string

Street name.

profile.residentialAddress.townCity
string

Town or city.

profile.residentialAddress.region
string

Region/County/State/Province.

profile.residentialAddress.postalCode
string

Postal Code or ZIP.

profile.residentialAddress.countryISO
string

Country code

Format

Two-letter ISO 3166-1 alpha-2 code.

e.g. GB

profile.firstName
string

The first name of the individual.

profile.lastName
string

The last name of the individual.

profile.dob
date

The date of the birth of the individual, in UTC.

Input Date Formats

profile.accountPurpose
enum

A description of what the account will be used for.

enum

FREELANCE, GAMING, SALARY, INVESTMENT, OTHER, PURCHASE_GOODS_AND_SERVICES, SELL_GOODS_AND_SERVICES, SAVINGS, FRIENDS_AND_FAMILY,

preferredInstruments.card.id
string

The unique identifier of the card or bank_account that is the preferredInstrument.

Format

_entity_/_uuid_

e.g. card/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

bank_account/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

preferredInstruments.card.updatedAt
date

The timestamp in UTC at which the entity was last updated.

preferredInstruments.bankAccount.id
string

The unique identifier of the card or bank_account that is the preferredInstrument.

Format

_entity_/_uuid_

e.g. card/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

bank_account/62dc1d23-d473-46a6-b4b3-e63c3f6d4658

preferredInstruments.bankAccount.updatedAt
date

The timestamp in UTC at which the entity was last updated.