Paying too much to process cards? Get a cheaper quote today.Schedule a call →

Customers

5 endpoints. Base URL https://api.paymentsonline.io, sandbox https://api.sandbox-paymentsonline.io.

Every request needs payments-api-key and payments-account.

GET/v1/customers

List all Customers

Returns a list of Customers. The Customers are sorted with the most recently created appearing first.

Query parameters

  • metadataobjectoptional

    metadata key-value pairs to filter by. Only exact matches on the key-value pair(s) will be returned. Example: ?metadata[internal_customer_id]=7cb1159d-875e-47ae-a309-319fa7ff395b.

  • qstringoptional

    The partial search of text fields. Supports searching by customer.first_name, customer.last_name, customer.email, customer.phone

  • offsetnumberoptional

    The (zero-based) offset of the first item in the collection to return.

  • limitnumberoptional

    The maximum number of entries to return. If the value exceeds the maximum, then the maximum value will be used.

Header parameters

  • payments-accountstringrequired

    The id of the Paydude Account (usually starting with the prefix acct_) that the request is performed on behalf of. Must be a merchant (connected) account id, not the partner account you signed up with; a partner account passes GET /v1/accounts and then fails with "not enabled for this account" on the first payment call.

Responses

200PaginatedDto | object

  • has_morebooleanrequired

    Whether or not there are more elements available after this set. If false, this set comprises the end of the list.

  • limitnumberoptional

    The maximum number of entries to return. If the value exceeds the maximum, then the maximum value will be used.

  • offsetnumberoptional

    The (zero-based) offset of the first item in the collection to return.

  • totalnumberoptional

    The total items count.

  • itemsarray of Customerrequired

POST/v1/customers

Create a Customer

Creates a Customer.

Header parameters

  • payments-accountstringrequired

    The id of the Paydude Account (usually starting with the prefix acct_) that the request is performed on behalf of. Must be a merchant (connected) account id, not the partner account you signed up with; a partner account passes GET /v1/accounts and then fails with "not enabled for this account" on the first payment call.

Request body application/jsonrequired

  • emailstringoptional

    The customer's email address.

  • first_namestringoptional

    The customer's first name.

  • last_namestringoptional

    The customer's last name.

  • metadataobjectoptional

    Set of [key-value pairs](#section/Metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value (i.e. '' or null) to them. All keys can be unset by posting an empty value (i.e. {} or null) to metadata.

  • middle_namestringoptional

    The customer's middle name.

  • phonestringoptional

    The customer's phone number.

Example request

{
  "email": "test@email.test",
  "first_name": "Jane",
  "middle_name": "Andrea",
  "last_name": "Doe",
  "metadata": {
    "order_id": "100123",
    "internal_customer_id": "7cb1159d-875e-47ae-a309-319fa7ff395b"
  },
  "phone": "1234567890"
}

Responses

201Customer

  • account_idstringrequired

    The id of the associated account.

  • created_atstring date-timerequired

    Time at which the object was created.

  • emailstringoptional

    The customer's email address.

  • first_namestringoptional

    The customer's first name.

  • idstringrequired

    Unique identifier for the object.

  • last_namestringoptional

    The customer's last name.

  • metadataobjectoptional

    Set of [key-value pairs](#section/Metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

  • middle_namestringoptional

    The customer's middle name.

  • phonestringoptional

    The customer's phone number.

  • updated_atstring date-timerequired

    Time at which the object was last updated.

DELETE/v1/customers/{id}

Delete a Customer

Deletes a Customer. This cannot be undone.

Path parameters

  • idstringrequired

Header parameters

  • payments-accountstringrequired

    The id of the Paydude Account (usually starting with the prefix acct_) that the request is performed on behalf of. Must be a merchant (connected) account id, not the partner account you signed up with; a partner account passes GET /v1/accounts and then fails with "not enabled for this account" on the first payment call.

Responses

204object

GET/v1/customers/{id}

Get a Customer

Retrieves the details of an existing Customer.

Path parameters

  • idstringrequired

Header parameters

  • payments-accountstringrequired

    The id of the Paydude Account (usually starting with the prefix acct_) that the request is performed on behalf of. Must be a merchant (connected) account id, not the partner account you signed up with; a partner account passes GET /v1/accounts and then fails with "not enabled for this account" on the first payment call.

Responses

200Customer

  • account_idstringrequired

    The id of the associated account.

  • created_atstring date-timerequired

    Time at which the object was created.

  • emailstringoptional

    The customer's email address.

  • first_namestringoptional

    The customer's first name.

  • idstringrequired

    Unique identifier for the object.

  • last_namestringoptional

    The customer's last name.

  • metadataobjectoptional

    Set of [key-value pairs](#section/Metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

  • middle_namestringoptional

    The customer's middle name.

  • phonestringoptional

    The customer's phone number.

  • updated_atstring date-timerequired

    Time at which the object was last updated.

PATCH/v1/customers/{id}

Update a Customer

Updates a Customer by setting the values of the provided parameters. Any parameters not provided will be left unchanged.

Path parameters

  • idstringrequired

Header parameters

  • payments-accountstringrequired

    The id of the Paydude Account (usually starting with the prefix acct_) that the request is performed on behalf of. Must be a merchant (connected) account id, not the partner account you signed up with; a partner account passes GET /v1/accounts and then fails with "not enabled for this account" on the first payment call.

Request body application/jsonrequired

  • emailstringoptional

    The customer's email address.

  • first_namestringoptional

    The customer's first name.

  • last_namestringoptional

    The customer's last name.

  • metadataobjectoptional

    Set of [key-value pairs](#section/Metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value (i.e. '' or null) to them. All keys can be unset by posting an empty value (i.e. {} or null) to metadata.

  • middle_namestringoptional

    The customer's middle name.

  • phonestringoptional

    The customer's phone number.

Responses

200Customer

  • account_idstringrequired

    The id of the associated account.

  • created_atstring date-timerequired

    Time at which the object was created.

  • emailstringoptional

    The customer's email address.

  • first_namestringoptional

    The customer's first name.

  • idstringrequired

    Unique identifier for the object.

  • last_namestringoptional

    The customer's last name.

  • metadataobjectoptional

    Set of [key-value pairs](#section/Metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.

  • middle_namestringoptional

    The customer's middle name.

  • phonestringoptional

    The customer's phone number.

  • updated_atstring date-timerequired

    Time at which the object was last updated.