Members

Member accessing and altering endpoints.

get

Returns all members for a given merchant. Merchant is pulled from the public API key for security reasons. Pagination is supported by passing limit and lastCustomerId values as query parameters. You will get a lastCustomerId value in the response of the previous request, which can be used for the next.

Query parameters
limitstringRequired
lastCustomerIdstringRequired
Header parameters
X-Inveterate-Api-KeystringRequired

Your private Inveterate API key.

Responses
200
Returned upon successful direct action to our database. Action is immediate.
application/json
get
GET /v2.0/admin/members?limit=text&lastCustomerId=text HTTP/1.1
Host: 
X-Inveterate-Api-Key: text
Accept: */*
{
  "message": "text",
  "data": {}
}
post

This endpoint is used to create a free tier member. You can also provide a credit value to add credits to the new members account. The overrideSpendThreshold parameter allows you to add customers to a spend based tier, and the keepInSpendBasedTier parameter ensures that the member won't be downgraded if they don't hit the spend minimum. NOTE: This endpoint will downgrade a customer specified to a lower tier if that is the tier provided to the endpoint!

Header parameters
X-Inveterate-Api-KeystringRequired

Your private Inveterate API key.

Body
customerIdstringRequired

The customerId to add to the specified free tier.

referralsstringRequired

The signify whether or not the customer was referred. NOTE: NOT to be used to indicate the referring customer.

segmentIdstringRequired

The segmentId of the tier you want to add this customer to.

overrideSpendThresholdbooleanRequired

Whether or not to override the spend required to add a customer to a spend based tier.

keepInSpendBasedTierbooleanRequired

Whether or not you want to keep this customer in the spend based tier despite not meeting the spend threshold.

creditsnumber · min: 1Required

Especially for member creation requests, if you would like to add some credits to the specified customer.

birthdaystringRequired

The customer's date of birth in YYYY-MM-DD format, e.g "1988-04-01"

Responses
201
Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.
application/json
post
POST /v2.0/admin/members HTTP/1.1
Host: 
X-Inveterate-Api-Key: text
Content-Type: application/json
Accept: */*
Content-Length: 147

{
  "customerId": "text",
  "referrals": "text",
  "segmentId": "text",
  "overrideSpendThreshold": true,
  "keepInSpendBasedTier": true,
  "credits": 1,
  "birthday": "text"
}
{
  "message": "text",
  "data": {}
}
get

Returns a single member for a given merchant. Merchant is pulled from the public API key for security reasons.

Path parameters
idstringRequired

The customer ID number which you would like to retrieve.

Header parameters
X-Inveterate-Api-KeystringRequired

Your private Inveterate API key.

Responses
200
Returned upon successful direct action to our database. Action is immediate.
application/json
get
GET /v2.0/admin/members/{id} HTTP/1.1
Host: 
X-Inveterate-Api-Key: text
Accept: */*
{
  "message": "text",
  "data": {}
}
patch

This endpoint is used to update a member. It takes a member ID and uses your public API key to match the customer to your account. As of now, all fields in the update schema are required, so it is not possible to update a single field at a time.

Path parameters
idstringRequired

The customer ID number which you would like to update.

Header parameters
X-Inveterate-Api-KeystringRequired

Your private Inveterate API key.

Body
firstNamestringRequired

The customer's first name.

lastNamestringRequired

The customer's last name.

notesstringRequired

Internal notes for this customer. Only viewable by the merchant.

phoneNumberstringRequired

The customer's phone number.

birthdaystringRequired

The customer's date of birth in YYYY-MM-DD format, e.g "1988-04-01"

Responses
201
Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.
application/json
patch
PATCH /v2.0/admin/members/{id} HTTP/1.1
Host: 
X-Inveterate-Api-Key: text
Content-Type: application/json
Accept: */*
Content-Length: 92

{
  "firstName": "text",
  "lastName": "text",
  "notes": "text",
  "phoneNumber": "text",
  "birthday": "text"
}
{
  "message": "text",
  "data": {}
}

Last updated

Was this helpful?