BackOffice Admin
Welcome to the CRM.COM Application Programming Interface (API) documentation
The CRM.COM API is designed around REST, allowing you to access and extend the software’s current functionality in a simple, programmatic way using intuitive URL endpoints, conventional HTTP requests, response codes, authentication and verbs.
Back-Office API is designed with a main focus on users and external systems that desire to access and extend the functionality found in CRM.COM.
For the Mobile/Web based Applications API please refer to the Self-Service API documentation that provides more details how to allow customer to manage their subscriptions and/or reward accounts.
CRM.COM is built on a domain based micro-service architecture. Our primary resources such as Contact, Account, Wallet, Products, Subscriptions are all created with a unique identifier that uses a performant time based GUID. These are generated when a new resource such as a contact is created. However in some cases external integration may wish to use a unique identfier that is stored in an external system, such as a Bank CIF or Credit Card fingerprint.
Some systems allow from their create APIs to supply a unique identifier as part of the request body. CRM.COM has decided to provide an alternative approach and make an alternative unique identifier available on resources (e.g. on Contacts we provide the contact.code). If such attribute is specified during the create operation it wil be available on subsequent operations as a resource’s identifier, alongside with the GUID that is returned in the response body.
CRM.COM API is organized around REST. Our API has specific resource-oriented URLs, accepts form-encoded request bodies, returns JSON-encoded responses and uses standard HTTP response codes, authentication & verbs.
You can use the entire API in test mode, which does not affect your live data. The API Key used to authenticate any of your requests will determine whether the request is on live mode or test mode.
The API may differ based on each CRM.COM release. For every new release with noticable changes that might alter backwards compatibility, a new version will be created.
CRM.COM Back-Office API uses either API Keys to authenticate requests or an authentication JWT token obtained from a user successful logging in.
All API requests must be made over HTTPS. Any request made over plain HTTP or without authentication will fail. In addition, API Keys carry many privileges, so be sure to keep them secure! Do not share your secret API Keys in publicly accessible areas, such as GitHub or client-side code.
API KEY AUTHORIZATION HEADER EXAMPLE
curl -X $HTTP_METHOD -H "api_key: 2189341e-981e-9ad5-9912-11101670314a"
AUTH TOKEN AUTHORIZATION HEADER EXAMPLE
curl -X $HTTP_METHOD -H "authorization: Bearer JWT_TOKEN"
API requests should be made using the HTTPS protocol so that traffic is encrypted. The interface responds to different methods depending on the action required.
Method | Usage |
---|---|
POST | To create a new object, your request should specify the POST method. The POST request includes all of the attributes necessary to create a new object to the targeted endpoint. |
PUT | To update the information on an existing object, the PUT method should be used. This will update the specified object if it is found using the provided values, regardless of their current values. If it is not found, the operation will return a response indicating that the object was not found. This idempotency means that you do not have to check for a resource’s availability prior to issuing an update command, the final state will be the same regardless of its existence. Requests using the PUT method do not need to check the current attributes of the object. |
DELETE | To remove an existing object from your environment, the DELETE method should be used. Similar to PUT method, the DELETE method is idempotent. |
GET | For retrieving information about contacts, purchases or orders, the GET method should be used. Any requested information will be returned as a JSON object. The attributes defined by the JSON object can be used to form additional requests. Any request using the GET method is read-only and will not affect any of the retrieved objects. |
Along with the HTTP methods that the API responds to, CRM.COM uses conventional HTTP response codes and human-readable messages in JSON format to indicate the success or failure of an API request.
In the event of a problem, the status will contain the error code, while the body of the response will usually contain additional information about the problem that was encountered.
HTTP Status | Description |
---|---|
2XX | Return codes in the 200 range indicate that the request was fulfilled successfully and that no error was encountered. |
4XX | Return codes in the 400 range, typically, indicate that there was an issue with the request that was sent. Most common reasons could be an invalid authentication method, unauthorised requests or the object that you are requesting does not exist. |
5XX | Return codes in the 500 range indicate that there is a server-side problem and CRM.COM cannot fulfill your request at the moment. |
Most of our 4XX range errors that could be handled programmatically contain all the necessary details for a better integration handling. Such details are
- HTTP Status Code & Error are used for programmatic consumption
- Message is human-readable and can be used as a default error message
- Parameters are used for programmatic consumption and can be used for enhancing the interface error message with additional information
4XX ERROR RESPONSE EXAMPLE
An example of a customer not found error is as follows
HTTP/1.1 404 Not Found
{
"status": 404,
"message": "Record not found.",
"error": "CRM.EXCEPTIONS.NOTFOUNDEXCEPTION",
"parameters": [
"contact",
"789dacae-cf71-414f-9483-ca88acaa46432"
]
}
The request has succeeded
The input request was invalid or incorrect, often due to missing a required parameter
The provided API Key or Token is invalid
The API key or Token does not have permissions to perform the request
The requested resource does not exist
The server encountered an unexpected condition which prevented it from fulfilling the request
The server received an invalid response from the upstream server it accessed in attempting to fulfill the request
The server is currently unable to handle the request due to a temporary overloading or maintenance
The server did not receive a timely response from the upstream server
What is an account
{id}
/accounts{id}
{id}
/accounts{id}
/life_cycle_state{id}
/accountsAdd a new customer account to an existing contact
Path variables
The contact identifier that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The account’s classification ID
The account’s currency
If set to true, then the account will be set as the primary one even if a different one exists
The unique identification of a contact address which will be set as the billing address of the account. By default, the primary addres (if it exists) will be provided
Responses
OK
Body
The account identifier
POST https://sandbox.crm.com/backoffice/v1/contacts/CAD1E31269B76D7A65ACCE45B2E68DFD/accounts HTTP/1.1
Content-Type: application/json
{
"classification_id": "4AD9C84FA60F9FE407140E20F707726A",
"currency_code": "EUR",
"is_primary": true,
"billing_address_id": "E407140E20F707726A4AD9C84FA60F9F"
}
{id}
Update the account of a contact
Path variables
The account identifier that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The account’s classification ID
If set to true, then the account will be set as the primary one even if a different one exists
The unique identification of a contact address which will be set as the billing address of the account. By default, the primary addres (if exists) will be provided
Sets the credit limit of the account
Sets the Account’s Payment Terms.
Responses
OK
Body
The account identifier
PUT https://sandbox.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD HTTP/1.1
Content-Type: application/json
{
"classification_id": "4AD9C84FA60F9FE407140E20F707726A",
"is_primary": true,
"billing_address_id": "4AD9C84FA60F9FE407140E20F707726A",
"credit_limit": 200,
"payment_terms_id": "4AD9C84FA60F9FE407140E20F707726A"
}
{id}
/accountsGet a list of Contact Accounts. Normally a contact will have a single account but multiple accounts can be used to service different currencies, or different spending profiles.
Path variables
The contact identifier whose accounts will be retrieved
Request parameters
If set to true, then only the primary account of the contact will get retrieved
Retrieve accounts with a specific life cycle state
Defines on which attribute the results should be sorted
The page number that should be retrieved
The size (total records) of each page
Defines how the results will be ordered
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
The account identifier
Indicates if this is the primary account of the contact
The account name
The Account number
The account’s life cycle state
The account’s currency
Details about the event classification
The classification identifier
The classification name
The account’s calculated balance
The account’s credit limit
The unpaid amount that is passed its due date
The account’s Payment Terms
Wallet related to the Account
Wallet identifier
Wallet code
Wallet total balance
Currency code
Wallet’s state
GET https://sandbox.crm.com/backoffice/v1/contacts/CAD1E31269B76D7A65ACCE45B2E68DFD/accounts HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"is_primary": true,
"name": "Default",
"number": "AC123456",
"life_cycle _state": "ACTIVE",
"currency_code": "EUR",
"classification": {
"id": "c8d83493-3f50-40df-adb0-762ec5f41863",
"name": "Delivery Purchase"
},
"balance": 200,
"credit_limit": 100,
"overdue_amount": 50,
"payment_terms": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Net 7"
},
"wallet": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"code": "9005455565111112",
"balance": 9.99,
"currency_code": "EUR",
"life_cycle_state": "EFFECTIVE"
}
}
]
}
{id}
/life_cycle_stateChange the life cycle state of the Account
Path variables
The account identifier that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The life cycle state that the account will changed into
The account to which any account balance will get transfered, in case of Termination. Required when terminating the account
Responses
Successful Request
Body
The unique identifier of the account
POST https://sandbox.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/life_cycle_state HTTP/1.1
Content-Type: application/json
{
"life_cycle_state": "SUSPENDED",
"transfer_to_account_id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
/financials{id}
/financialsGet a single Account with its financial information
Path variables
The unique identification of the Account to be retrieved.
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
The account’s name
The account’s number
Defines whether the account is the primary one of the contact
The account’s life cycle state
The account’s currency (3 code currency)
The account’s calculated balance
The unpaid amount that is passed its due date
The account’s credit limit
The opening balance brought forwards after the latest closed accounting period
Details about the event classification
The classification identifier
The classification name
The latest accounting period for which the account’s opening balance was calculated
The ID of the latest closed accounting period
The name of the account’s latest accounting period
The id of the billing address
The account’s payment terms
Payment terms identifier
Payment terms name
The account’s related Wallet
Wallet identifier
Wallet code
The wallet life cycle state
Total balance
Open balance
Commerce balance
The minimum wallet balance threshold. If not provided, the global rules apply
The minimum amount allowed
The maximum amount allowed
The period for which the limit is applied
The wallet transaction type for which the limit is applied
Sets the threshold for the auto topup to be performed
The amount to get topped up
Indicates the method of collecting money
The contact’s actual preferred payment method. Required and mandatory only for online payments (Card, Wallet and Account Debit). Defaults to the primary payment method, if any.
GET https://sandbox.crm.com/backoffice/v1/accounts/4AD9C84FA60F9FE407140E20F707726A/financials HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"name": "John Smith AC00123456",
"number": "AC00123456",
"is_primary": "true",
"life_cycle_state": "TERMINATED",
"currency_code": "EUR",
"balance": 200,
"overdue_amount": 100.5,
"credit_limit": 98,
"opening_balance": 100.5,
"classification": {
"id": "c8d83493-3f50-40df-adb0-762ec5f41863",
"name": "Delivery Purchase"
},
"accounting_period": {
"id": "",
"name": "OCTOBER2018"
},
"billing_address": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"address_line_1": "2265 Oak Street",
"address_line_2": "",
"state_province_county": "New York",
"town_city": "Old Forge",
"postal_code": "13420",
"country_code": "USA"
},
"payment_terms": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Net 7"
},
"wallet": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"code": "9000004434321111",
"life_cycle_state": "TERMINATED",
"balance": 9.99,
"open_balance": 5.45,
"commerce_balance": 4.54,
"currency_code": "EUR",
"minimum_balance": 5.99,
"limits": [
{
"minimum_amount": 5.99,
"maximum_amount": 99.99,
"period": "MONTHLY",
"transaction_type": "CREDIT"
}
],
"auto_topup": {
"threshold": 99.99,
"amount": "9.99",
"payment_method": "CARD",
"payment_method_id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
}
}
{id}
/rewards{id}
/rewards{id}
/reward_schemes{id}
/reward_schemes/{reward_scheme_id}
{id}
/merchants{id}
/merchants/{merchant_id}
{id}
/rewardsUpdate the reward attributes of the primary account of a contact
Path variables
The account (identifier) whose reward attributes will be updated
Notes
Only Primary Accounts of a Contact hold Reward information
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The date that the customer first signed up
The organisation identifier that signed up the customer (first time)
Defines whether the spending is blocked for the specific account
Information about the automatic spend settings for the account
Defines whether automatic spend is enabled for the account
Defines whether automatic spends will occur on the next purchase of a specific merchant or based on wallet balance and purchase amount to a group of merchants
The minimum wallet balance amount that should be available for the spend to be performed. Applicable when automatic spend preference is for all merchant purchases
The min amount (inclusive) that the purchase customer event total amount should be in order for the automatic spend to be applied. Applicable when automatic spend preference is for all merchant purchases
Responses
OK
Body
The account identifier
PUT https://devapi.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/rewards HTTP/1.1
Content-Type: application/json
authorization: 4AD9C84FA60F9FE407140E20F707726A
{
"signed_up_on": 1583846865,
"signed_up_organisation_id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"spending_blocked_status": "true",
"automatic_spend_settings": {
"enable_automatic_spend": "false",
"automatic_spend_preference": "ALL_MERCHANT_PURCHASE",
"minimum_wallet_balance": 1,
"from_purchase_amount": 1.76
},
"preferred_payment_method_id": "CAD1E31269B76D7A65ACCE45B2E68DCD"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
/rewardsGet a single account, along with its reward details
Path variables
The account (identifier) which reward details will be retrieved
Notes
Only Primary Accounts of a Contact hold Reward information
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
The account identifier
The account’s name
The account’s number
The account’s currency (3 code currency)
The date when the account was signed up for the first time
Information about the organisation that sign up the account for the first time
The organisation identifier
The organisation name
Defines whether the account can spend or not
The date that the spending status of the account was updated
Information about the user that updated the spending status of the account
The user identifier
The user’s email address
The user’s first name
The user’s last name
Information about the automatic spend settings for the account
Defines whether automatic spend is enabled for the account
Defines whether automatic spends will occur on the next purchase of a specific merchant or based on wallet balance and purchase amount to a group of merchants
The minimum wallet balance amount that should be available for the spend to be performed. Applicable when automatic spend preference is for all merchant purchases
The min amount (inclusive) that the purchase customer event total amount should be in order for the automatic spend to be applied. Applicable when automatic spend preference is for all merchant purchases
Information about the merchants that automatic spending is allowed (Deprecated, replaced by Organisations)
The merchant record identifier
Defines whether the merchant is setup for automatic spend on the next visit
Information about organisation
The organisation identifier
The organisation name
Information about the account’s reward tier
The reward tier identifier
The reward tier name
The designated hexadecimal code of the tier’s color
The account’s value units that accumulated during the last rolling period
The account’s value units that accumulated overall
Details about The progression percentage for each reward tier
The progression percentage until the reward tier
Details about the reward tier
The reward tier identifier
The reward tier name
The tier (threshold) value units (inclusive)
The remaining value units to reach this tier
Information about the reward schemes that the account has signed up to
The reward scheme identifier
The reward scheme name
The date when the account was signed up on the specific reward scheme
The email address that was used during sign up (applicable if the reward scheme is a close loop scheme based on email domains)
Defines how customers can sign up to the reward scheme
GET https://sandbox.crm.com/backoffice/v1/accounts/41dc3d8a-5ab2-3dc8-83d5-33501eb1949f/rewards HTTP/1.1
api_key: adea79a6-fe7f-2e92-56c7-9a0685ffa290
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "John Smith AC00123456",
"number": "AC00123456",
"currency_code": "EUR",
"reward_tier": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Gold",
"color": "#d4af37",
"period_value_units": 222,
"lifetime_value_units": 333,
"next_tier_progression": 45.98
}
}
{id}
/reward_schemesSign up the account to a specific reward scheme
Path variables
The account (identifier) that will be signed up to the reward scheme
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The reward scheme that the account has signed up
The email address of the customer requestng to sign uo to a reward scheme based on supported domains
The code that will verify that the customer is allowed to sign up to a close loop reward scheme
The date that the account has signed up (if not specified, defaults to current date)
Responses
OK
Body
The reward scheme identifier
POST https://devapi.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/reward_schemes HTTP/1.1
Content-Type: application/json
authorization: 4AD9C84FA60F9FE407140E20F707726A
{
"reward_scheme_id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"email_address": "johndoe@crm.com",
"sign_up_code": "ABCDEFG1234"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DXD"
}
{id}
/reward_schemes/{reward_scheme_id}
Sign out the account from a specific reward scheme
Path variables
The account (identifier) that will be signed off from the reward scheme
The reward scheme (identifier) that the account has signed off
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
DELETE https://devapi.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/reward_schemes/CAD1E31269B76D7A65ACCE45B2E68DXD HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
{id}
/merchantsAdd a set of new merchants for automatic spends for that account
Path variables
The account (identifier) whose merchant preferencees will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
Defines a list of merchants that are authorised to perform automatic awards spending for that account
The organisation identifier that should be authorised to perform automatic awards spending
Defines whether the merchant is setup for automatic spend on the next visit
Responses
OK
Body
A list of merchants that are authorised to perform automatic awards spending for that account
The organisation identifier
POST https://devapi.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/merchants HTTP/1.1
Content-Type: application/json
authorization: 4AD9C84FA60F9FE407140E20F707726A
{
"merchants": [
{
"organisation_id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"is_next_visit": "false"
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"merchants": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
]
}
{id}
/merchants/{merchant_id}
Remove an exisintg merchant from an account’s automatic spend preferences
Path variables
The account (identifier) whose reward attributes will be updated
The merchant (identifier) that will be removed from the spend preferences
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
DELETE https://devapi.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/merchants/CAD1E31269B76D7A65ACCE45B2E68DFD HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
{id}
/wallets{id}
/walletsAdds a new Wallet to an Account. This is allowed only if the account is not related to any wallet or if the account’s related wallet was previously Terminated. So an Account can only be related to a single Effective Wallet at a time.
Path variables
Account identifier
Request body
The minimum wallet balance threshold. If not provided, the global rules apply
Defines the limit rules applied on specific wallet. If not provided, the global rules apply
The maximum amount allowed
The wallet transaction type for which the limit is applied
The period for which the limit is applied
Responses
Body
The Wallet identifier
POST https://sandbox.crm.com/backoffice/v1/accounts/CAD1E31269B76D7A65ACCE45B2E68DFD/wallets HTTP/1.1
Content-Type: application/json
{
"minimum_balance": 10.99,
"limit_rules": [
{
"limit_amount": 100.99,
"transaction_type": "DEBIT",
"period": "MONTHLY"
}
]
}
HTTP/1.1 201 Created
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
{id}
/actions{id}
/commerce_balances{id}
Updates a single Wallet.
Path variables
The unique identifier of the Wallet to be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
Wallet’s auto top up settings.
The wallet’s minimim balance threshold that triggers this rules once it is reached
The auto top up’s amount
The payment method from which funds will be automatically retrieved
The contact’s payment method identifier.
["TOPUP"]
Responses
Body
The unique identifier of the updated Wallet
PUT https://sandbox.crm.com/backoffice/v1/wallets/4dc0809f-ed91-4b68-b912-5bd6064d901e HTTP/1.1
Content-Type: application/json
{
"auto_topup": {
"threshold": 0.01,
"amount": 10.5,
"payment_method": {
"type": "CARD",
"id": "4dc0809f-ed91-4b68-b912-5bd6064d901e"
}
},
"termed_topup": {
"amount": 10.5,
"frequency": {
"period": "MONTHS",
"value": 1
},
"topup_day": {
"day_of_month": 1,
"day_of_week": "MONDAY"
},
"payment_method": {
"type": "",
"id": ""
}
},
"limit_rules": [
{
"name": "VIP",
"maximum_amount": 9.99,
"maximum_number": 10,
"period": "ANNUAL",
"transaction_type": [
"TOPUP"
]
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "3ac0809f-ed91-4b68-b912-5bd6064d901e"
}
{id}
/actionsUpdates an existing Wallet’s state
Path variables
Wallet identifier
Request headers
Authorization Token
The public api key required for API calls to identify the organisation
Request body
Defines the life cycle state of the wallet. If selected, then all of the above will not be taken into consideration
Responses
Body
The updated wallet’s identifier
POST https://sandbox.crm.com/backoffice/v1/wallets/234fbc54-bc32-1990-ce59-76c45e6377a8/actions HTTP/1.1
api_key: 8c54d563-b991-4b76-8a83-557c08166f95
Content-Type: application/json
{
"action": "TERMINATED"
}
HTTP/1.1 201 Created
Content-Type: application/json
{
"id": "234fbc54-bc32-1990-ce59-76c45e6377a8"
}
{id}
/commerce_balancesRetrieves a wallet’s business balance breakdown. The balance is returned per spend condition which credited the wallet’s business balance, along with the spend condition’s details
Path variables
The unique identification of the wallet whose balance spend conditions will be retrieved.
Request parameters
The id of a specific spend condition (optional). If not provided then all spend conditions are retrieved
If set to true, then the expiration information will also be retrieved
If not specified, then the balance breakdown of the wallet’s primary currency will be returned by default.
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
The spend condition group identifier
The name of the spend condition group
The amount that is allocated to the specified spend condition
The organisations where the amount can be spent at
The organsiation identifier
The name of the organisation
The location of the organisation
Information about the organisation’s location
The name of the location
The address of the location
Additional address information about the location
The state/province/county of the location
The town/city of the location
The postal code of the location
The country code of the location
The latitude of the location
The longitude of the location
The Google textual identifier that uniquely identifies a location
The products that the amount can be spent for
The type of the ID to be provided
The ID of the product (based on the type provided)
The name of the product
The descrtipion of the product
The time when the amount can be spent
The month as a condition (1-12)
The day of the week as condition (1-7), 1 is Sunday
The start time of the day in 24 Hour format
The end time of the day in 24 Hour format
Defines the amounts expiring in periods. Available only if the parameter include_expiration is set to true
The amount that will expire in up to 30 days
The amount that will expire from 30 to 60 days
The amount that will expire from 60 to 90 days
The amount that will expire in more than 90 days
GET https://sandbox.crm.com/backoffice/v1/wallets/234fbc54-bc32-1990-ce59-76c45e6377a8/commerce_balances HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
[
{
"id": "234fbc54-bc32-1990-ce59-76c45e6377a8",
"name": "Happy Hour",
"amount": 100.5,
"curency_code": "",
"organisations": [
{
"id": "234fbc54-bc32-1990-ce59-76c45e6377a8",
"name": "Cafe",
"locations": [
{
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"lat": 35.157115,
"lon": 33.313719,
"google_place_id": "ChIJrTLr-GyuEmsRBfy61i59si0"
}
]
}
],
"products": [
{
"id_type": "BRAND",
"id": "234fbc54-bc32-1990-ce59-76c45e6377a8",
"name": "Coffee",
"description": "Brazilian Coffee"
}
],
"timings": [
{
"month": 1,
"day": 1,
"start_time": "19:00",
"end_time": "21:00"
}
],
"expiration": {
"zero_to_thirty": 50.5,
"thirty_to_sixty": 50.5,
"sixty_to_ninety": 50.5,
"ninety_plus": 50.5
}
}
]
Creates a Wallet Journal Entry that either debits or credits the wallet. A single journal entry is created per Web API call.
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The unique identifier for which the journal entry will be created
The amount of the journal
If not specified, then the wallet’s primary currency is used to log the journal entry
The description of the journal
The type of the journal
The unique identifier of the related spend condition. If specified, then the journal entry’s amount is move to the wallet’s business balance
The valid from date
The valid to date
The date and time when the journal actually created
Allows a wallet debit journal to take the wallet balance below zero. By default, the wallet balance cannot go below zero.
Responses
OK
Body
The wallet journal identifier
POST https://devapi.crm.com/backoffice/v1/journals HTTP/1.1
Content-Type: application/json
{
"wallet_id": "4AD9C84FA60F9FE407140E20F707726A",
"amount": 10,
"type": "DEBIT",
"description": "Credit adjustment by 10 EUR",
"spend_condition_id": "4AD9C84FA60F9FE407140E20F707726A",
"valid_from": 1587988965,
"valid_to": 1587988965,
"created_on": 1588081851
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
{id}
{id}
/status{id}
Create a new activity
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The activity name
The activity description
The GUID of the activity type.
The date of the activity.
The date and time that is scheduled for the activity to take place
The date and time that is scheduled for the activity to be completed.
The id of the address associated with the contact. Either the address_id or the use_entity_address can be specified, not both
Use the entity address as the Activity address. In cases where an Activity is being created for an entity which has an address (e.g. Contact, Order, Service Request) then use that address as the default Activity address. Either the address_id or the use_entity_address can be specified, not both
Related linked entity details.
The type of related entity.
The related entity identifier
The user identifier
The team identifier
The custom field’s unique key
The custom field’s value
Responses
Successful Request
Body
The activity identifier that was created
POST https://sandbox.crm.com/backoffice/v1/activities HTTP/1.1
Content-Type: application/json
{
"name": "Call customer",
"description": "We need to call the customer (after 4pm) in order to schedule a demo",
"type_id": "CEEE83D6E0804A30966F684B0269AD91",
"date": 8634785,
"from_time": "09:00",
"to_time": "09:30",
"address_id": "JHGDSYGSDY656GFHGF",
"use_entity_address": "false",
"linked_to": [
{
"type": "ORDER",
"id": "CEEE83D6E0804A30966F684B0269AD91"
}
],
"user_id": "CEEE83D6E0804A30966F684B0269USER",
"assign_to": {
"user_id": "1edef819-0a1d-4d41-9d2a-d4bbc2ddbedf",
"team_id": "a43f08ca-998b-afbc-6ed4-c9dc2d136935"
},
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
]
}
{id}
Update an existing activity
Path variables
The activity identifier that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The activity name
The activity description
The address id associated to the contact and the activity
The date that the activity is scheduled.
The start time of the scheduled activity.
The end time of the scheduled activity.
Related linked entity details.
The type of the related entity
The related entity identifier
The user identifier
The team identifier
The custom field’s unique key
The custom field’s value
Responses
Successful Request
Body
The activity identifier that was updated
PUT https://sandbox.crm.com/backoffice/v1/activities/QWERTY1234543212345678UJIKY76HJR HTTP/1.1
Content-Type: application/json
{
"name": "Approve Offers",
"description": "Require 4 approvals for an offer",
"address_id": "GNEHDFHDBFDFFDSD",
"date": 863478,
"from_time": "09:00",
"to_time": "09:30",
"linked_to": [
{
"type": "ORDER",
"id": "CEEE83D6E0804A30966F684B0269AD91"
}
],
"user_id": "CEEE83D6E0804A30966F684B0269USER",
"assign_to": {
"user_id": "1edef819-0a1d-4d41-9d2a-d4bbc2ddbedf",
"team_id": "a43f08ca-998b-afbc-6ed4-c9dc2d136935"
},
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
]
}
{id}
Delete an existing activity
Path variables
The activity identifier that will be deleted
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Successful Request
DELETE https://devapi.crm.com/backoffice/v1/automations/QWERTY1234543212345678UJIKY76HJR HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
{id}
/statusUpdate an existing activity’s status
Path variables
The activity identifier whose life cycle state will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
Defines the new life cycle state of the activity
The activity will be created with this status.
The activity will be closed with this status.
The activity will be cancelled with this status.
Responses
Successful Request
Body
The activity identifier that was updated
PUT https://sandbox.crm.com/backoffice/v1/activities/QWERTY1234543212345678UJIKY76HJR/status HTTP/1.1
Content-Type: application/json
{
"status": "CANCELLED"
}
Search for activities
Request parameters
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Defines on which attribute the results should be sorted
Filter based on the related Order
Filter based on the related Lead
Filter based on the related Service Request
The id of the activity type
Search for an activity based on name
Filter based on the created date, which may fall within a given date range. The value can be a string with a date in epoch format. Each option must also include an operator. Use up to two options based on the required search (e.g. created_on[gte]=1618395497&created_on[lt]=1618395497).
Returns results where the created date is greater than this value
Returns results where the created date is greater than or equal to this value
Returns results where the created date is less than this value
Returns results where the created date is less then or equal to this value
Details pertaining to the statuses of the activities.
The id’s of the tags to filter by
Filter based on the User who is responsible to complete it
Filters based on specific assign to user
Filters based on specific assign to team
Retrieve custom fields?
Filters based on custom fields (key/value set should be semicolon separated)
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The activity identifier
The activity name
The activity description
The activity life cycle state
The date of the scheduled activity
The time from when the activity is scheduled.
The time that the activity is scheduled to finish.
The activity type
The id of the activity type
The name of the activity type
The colour code of the activity type
Details about the related contact
The contact identifier
The contact full name
The contact unique code
The details of the lead
The lead identifier
The name of the lead
The service request ticket number
The service request unique identifier
The ticket number of the service request
The order that the activity was created through
The order id
The order number
Details about the user that the record is assigned to
The user identifier
The user name
The username of the user
Details about the team that the record is assigned to
The team identifier
The team name
The custom field’s unique key
The custom field’s value
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/activities HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"name": "Call customer",
"number": "ACT1001",
"description": "We need to call the customer to arrange a demo",
"status": "COMPLETED",
"date": 198735487,
"from_time": "09:00",
"to_time": "09:30",
"activity_type": {
"id": "JKHGFSD878JHGDHJGD",
"name": "site visit",
"colour": "7GH86H7"
},
"contact": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "John Johnson",
"code": "C123"
},
"lead": {
"id": "AJBGJHFGKSF78676JHGS56",
"title": "ASOS"
},
"service_request": {
"id": "AJBGJHFGKSF78676JHGS56",
"number": "SR10001"
},
"order": {
"id": "JGDAKJHDAKJHAJK87897",
"number": "O101367"
},
"user": {
"id": "CEEE83D6E0804A30966F684B0269AD91",
"name": "John Doe"
},
"assign_to": {
"user": {
"id": "47ac694d-6281-b873-bf46-3fd8da334a3a",
"name": "John Doe",
"username": "j_doe@crm.com"
},
"team": {
"id": "bf1370a1-73ad-0bbf-6fef-f2ce1938d4fe",
"name": "Support"
}
},
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
]
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
Get details for a specific activity
Path variables
The activity identifier that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The activity identifier
The activity name
The activity description
The date and time that the activity is scheduled for
The time that the activity is scheduled to start.
The time that the activity is scheduled to be completed.
The date the activity was created.
The type of activity
The id of the type
the name of the type
the colour of the type.
Details about the related contact
The contact identifier
The contact full name
The contact unique code
The details of the sercice request
The id of the service request
The ticket number of the service request
The details of the lead
The id of the lead
The name of the lead
The order ID
The order number
The address of the activity
The life cycle states of the activity
The date that the activity enetered that stated
Details about the user that the record is assigned to
The user identifier
The user name
The username of the user
Details about the team that the record is assigned to
The team identifier
The team name
The custom field’s unique key
The custom field’s value
GET https://sandbox.crm.com/backoffice/v1/activities/CEEE83D6E0804A30966F684B0269AD91 HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"name": "Call customer",
"number": "ACT1001",
"description": "Arrange a call with the customer after 4pm to schedule a demo for next week",
"date": 7675675,
"from_time": "09:00",
"to_time": "09:30",
"created_date": 1,
"type": {
"id": "HGJDHGSJDHG",
"name": "site visit",
"color": "876FD5"
},
"contact": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "John Johnson",
"code": "C123"
},
"service_request": {
"id": "JHGHGF7576HGFTGD564654",
"number": "SRV78001"
},
"lead": {
"id": "JHGSD6576JKDGSFKJG",
"title": "ASOS"
},
"order": {
"id": "JGKDJSHSHDKAJHAKJD",
"number": "O10306P"
},
"address": {
"address_line_1": "Elia Papakyriakou",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2000",
"country": "CY",
"lat": "523654.098795",
"lon": "880932.981221",
"googleplaceid": "ad23rewf4472vnm90001"
},
"statuses": [
{
"status": "PENDING",
"date": ""
}
],
"user": {
"id": "CEEE83D6E0804A30966F684B0269AD91",
"name": "John Doe"
},
"assign_to": {
"user": {
"id": "47ac694d-6281-b873-bf46-3fd8da334a3a",
"name": "John Doe",
"username": "j_doe@crm.com"
},
"team": {
"id": "bf1370a1-73ad-0bbf-6fef-f2ce1938d4fe",
"name": "Support"
}
},
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
]
}
The following functionality relates to tags for activities
{id}
/tags{id}
/tags{id}
/tags/{tag_id}
{id}
/tags{id}
/tagsThe following process adds tags to an activity
Path variables
The activity GUID
Request headers
Authorization Token
The public api key required for API calls to identify the organisation
Request body
the content relating to the tag
The tag id
POST https://sandbox.crm.com/backoffice/v1/activities/HRDGSWRSFVSDSDBSDSSDDE/tags HTTP/1.1
api_key: 8c54d563-b991-4b76-8a83-557c08166f95
Content-Type: application/json
{
"tags": [
{
"id": "FDHNFDBR675765ghdh"
}
]
}
{id}
/tagsThe following process updates tags for an activity
Path variables
The activity GUID
Request headers
Authorization Token
The public api key required for API calls to identify the organisation
Request body
the content relating to the tag
The tag id
PUT https://sandbox.crm.com/backoffice/v1/activities/JGSDGJKAJKGDAKJGS/tags HTTP/1.1
api_key: 8c54d563-b991-4b76-8a83-557c08166f95
Content-Type: application/json
{
"tags": [
{
"id": "JGFJHGJHSDGHJSG"
}
]
}
{id}
/tags/{tag_id}
Deletes a tag on a activity.
Path variables
The id of the activity.
The id of the tag
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
DELETE https://sandbox.crm.com/backoffice/v1/activities/ef9a1f84-2d4b-c9eb-afc7-a142e202a9ef/tags/KJDFHKJGFSJHG HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
{id}
/tagsThe following process retrieves the tags for a activity
Path variables
The id of the activity.
Responses
Body
the tag ID
Name of Tag
Colour of tag
GET https://sandbox.crm.com/backoffice/v1/activities/JHGSDJHGAHJGD/tags HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "JKGJHFSDJHGDSJHGA",
"name": "Maintenance",
"colour": "The colour of the tag"
}
]
}
{id}
/analytics{id}
/analytics{id}
{id}
/{id}
{id}
/events{id}
/filters{id}
/breakdowns{id}
/results{id}
/preview{id}
/exportsCreate a new insight
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The insight name
The insight description
Responses
Body
The insight identifier
POST https://sandbox.crm.com/backoffice/v1/insights HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"name": "Marketing customers",
"description": "A list of customers that own an account"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "c0d4712e-6688-4604-b3d6-d084e4d2dc05"
}
{id}
Updates the basic information of an insight
Path variables
The insight identifier that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The insight name
The insight’s description
Responses
Body
The insight identifier
PUT https://sandbox.crm.com/backoffice/v1/insights/c0d4712e-6688-4604-b3d6-d084e4d2dc05 HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"name": "Rewards Award",
"description": "List of contacts owning a non-terminated account",
"refresh_frequency": 1
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "c0d4712e-6688-4604-b3d6-d084e4d2dc05"
}
{id}
/Delete an existing insight
Path variables
The insight identifier that will be deleted
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
DELETE https://sandbox.crm.com/backoffice/v1/insights/c0d4712e-6688-4604-b3d6-d084e4d2dc05/ HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Returns a list of insights
Request parameters
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The insights unique identifier
The insight’s name
The insights’s description
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/insights HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "4AD9C84FA60F9FE407140E20F707726A",
"name": "Marketing customers",
"descripion": "List customers owning an account"
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
Get all data for a single insight
Path variables
The insight identifier that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The insight identifier
The insight name
The event identifier
["Costa Coffee Nicosia"]
The filter identifier
The breakdown identifier
simple naming A, B, C used for ordering
GET https://sandbox.crm.com/backoffice/v1/insights/c0d4712e-6688-4604-b3d6-d084e4d2dc05 HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "c0d4712e-6688-4604-b3d6-d084e4d2dc05",
"name": "Rewards Award",
"events": [
{
"id": "c0d4712e-6688-4604-b3d6-d084e4d2dc05",
"name": "Purchases",
"event_name": "SPEND",
"totals": {
"is_frequency": true,
"property_name": "amount"
},
"criteria": [
{
"name": "A",
"property": {
"property": "venue.name",
"operator": "IS",
"value_list": [
"Costa Coffee Nicosia"
]
}
}
]
}
],
"filters": [
{
"id": "c0d4712e-6688-4604-b3d6-d084e4d2dc05",
"name": "",
"type": "CONTACT",
"property_name": "",
"operator": "NOT_EQUAL",
"min_value": "",
"max_value": "",
"value_list": [
""
]
}
],
"breakdowns": [
{
"id": "c0d4712e-6688-4604-b3d6-d084e4d2dc05",
"name": "",
"type": "CONTACT",
"property_name": "city"
}
]
}
{id}
/eventsAdds a set of events on an insight
Path variables
Request body
if the measurement is Freqency or Total of property
Name of the property to sum for a total or count frequency
List of selection operators
List of values if the operator is contains or single item if matching
Responses
POST https://sandbox.crm.com/backoffice/v1/insights/{id}/events HTTP/1.1
Content-Type: application/json
{
"events": [
{
"name": "Purchases",
"event_name": "SPEND",
"totals": {
"is_frequency": false,
"property_name": "amount"
},
"criteria": [
{
"name": "A",
"property": {
"property": "venue.name",
"operator": "IS",
"value_list": [
"Costa Coffee Nicosia"
]
}
}
]
}
]
}
{id}
/filtersAdds a set of filters on an insight
Path variables
Request body
Use Operator
Venue1,Venue2
Responses
POST https://sandbox.crm.com/backoffice/v1/insights/{id}/filters HTTP/1.1
Content-Type: application/json
{
"filters": [
{
"name": "",
"type": "EVENT",
"property_name": "",
"operator": "IS_NOT",
"min_value": "",
"max_value": "",
"value_list": [
""
]
}
]
}
HTTP/1.1 201 Created
{id}
/breakdownsAdds a set of breakdowns on an insight
Path variables
The insight identifier which breakdown will be set
Request body
name of the property to create the breakdown
Responses
POST https://sandbox.crm.com/backoffice/v1/insights/{id}/breakdowns HTTP/1.1
Content-Type: application/json
{
"breakdowns": [
{
"name": "",
"type": "CONTACT",
"property_name": ""
}
]
}
HTTP/1.1 201 Created
{id}
/resultsRetrieve results of a specific insight
Path variables
The insight identifier which results will be retrieved
Request parameters
The start date of the insight sequence
The end date of the insight sequence
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
A temporary identifier to link child levels
The identifier of the previous level
The breakdown level 0 = EVENTS
The name of the property within the group
The value of the property
The name of the event
The number of points can be used for frequency
The decimal amounts for the level
Applicable only if the property is a list and represents the list name
GET https://sandbox.crm.com/backoffice/v1/insights/04f28639-5ceb-a25e-1e44-b1109e533f42/results HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"breakdown": {
"id": "bb686ff0-e7a4-a8a6-05a6-cfe8e39f675f",
"parent_id": "bb686ff0-e7a4-a8a6-05a6-cfe8e39f675f",
"level": 1,
"property_name": "venue.name",
"property_value": "Costa Coffee Larnaca",
"event_name": "",
"count": 1,
"amount": 12.8,
"list_name": "products"
}
}
]
}
{id}
/previewPreview the results of a specific insight
Path variables
The insight identifier which results will be previewed
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The start date of the insight sequence
The end date of the insight sequence
if the measurement is Freqency or Total of property
Name of the property to sum for a total or count frequency
List of selection operators
List of values if the operator is contains or single item if matching
Use Operator
Venue1,Venue2
name of the property to create the breakdown
Responses
Body
A temporary identifier to link child levels
The identifier of the previous level
The breakdown level 0 = EVENTS
The name of the property within the group
The value of the property
The name of the event
The number of points can be used for frequency
The decimal amounts for the level
Applicable only if the property is a list and represents the list name
POST https://sandbox.crm.com/backoffice/v1/insights/62cb9ada-3a7b-cafb-b7a7-7c103011fa48/preview HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"start_date": 1612953199,
"end_date": 1612953199,
"events": [
{
"name": "Purchases",
"event_name": "PURCHASE",
"totals": {
"is_frequency": true,
"property_name": ""
},
"criteria": [
{
"name": "A",
"property": {
"property": "venue.name",
"operator": "IS_NOT",
"value_list": [
""
]
}
}
]
}
],
"filters": [
{
"name": "",
"type": "CONTACT",
"property_name": "",
"operator": "DOES_NOT_CONTAIN",
"min_value": "",
"max_value": "",
"value_list": [
""
]
}
],
"breakdowns": [
{
"name": "",
"type": "CONTACT",
"property_name": ""
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"breakdown": {
"id": "bb686ff0-e7a4-a8a6-05a6-cfe8e39f675f",
"parent_id": "bb686ff0-e7a4-a8a6-05a6-cfe8e39f675f",
"level": 1,
"property_name": "venue.name",
"property_value": "Costa Coffee Larnaca",
"event_name": "",
"count": 1,
"amount": 12.8,
"list_name": "products"
}
}
]
}
Get a list of distinct values for a contact or event property
Request parameters
Contact or Event collectioons
city
Responses
Body
Value of the property
GET https://sandbox.crm.com/backoffice/v1/distincts HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
[
{
"property_value": "London"
}
]
{id}
/exportsExport the results of a specific insight
Path variables
The insights (identifier) that will be exported
Request headers
Authorization Token
Request body
Defines what data should be exported from the related insight results
Export results in a tabular format, excluding underlying data
Export all underlying granular data that were used for this Insight
Defines the file format in which the exported data should be exported
CSV file
Responses
POST https://sandbox.crm.com/backoffice/v1/insights/efc5c8af-56ba-3d6f-d180-18be6dd04cc8/exports HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"type": "UGD",
"format": "csv"
}
HTTP/1.1 200 OK
{name}
/preview{name}
{id}
{id}
{id}
{name}
/previewRuns the report in preview mode, i.e. a subset of the report’s results are returned for preview purposes (max 10 records included in the response)
Path variables
The report (unique name) that will be previewed
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
Set of filters based on which the report runs
The filter’s name
The filter’s value as this was specified by the user
Set of columns that will be included in the report’s preview. Up to 10 columns are included by default
Number, Name
The field’s name
Responses
Body
POST https://sandbox.crm.com/backoffice/v1/reports/contacts_summary/preview HTTP/1.1
Content-Type: application/json
{
"filters_set": [
{
"key": "period_from",
"value": "This month"
}
],
"columns_set": [
{
"key": "product_code"
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"fields":[
{
"key": "Name",
"value": "Jane Smith"
}
]
}
]
}
{name}
Schedule a report and sends its results via email to a group of recipients
Path variables
The report (unique name) that will be scheduled
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The report’s format
Set of filters based on which the report runs
The filter’s label
The filter’s name
The filter’s value as this was specified by the user
The data type of the filter
Set of columns that will be included in the report
Number, Name
The ordering of the columns from left to right
The column’s label as this will be displayed on the report
The field’s name
The data type of the filter
Set of fields to be used to group the report’s results
The grouping’s ordering
The group by field’s label as this will be displayed on the report
The field’s name
The data type of the filter
Defines the scheduled report name (if not provided will be set based on the report’s unique name, e.g. Contacts Summary)
Defines the scheduler settings that will send a report on a recurring basis (if not specified, report will be generated and send only once)
Defines the period when report generation will take place
The repeat frequency provided as a cron expression pattern
Defines the recipients that will receive the report results (if not specified, will be send to the user that requested such report)
The type of recipients that will retrieve the report
Applicable only to Business organisations
The recipients that will retrieve the report
Responses
Runs a report and sends its results via email to the user who runs it
POST https://sandbox.crm.com/backoffice/v1/reports/contacts_summary HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"format": "CSV",
"filters_set": [
{
"label": "Registration date",
"key": "period_from",
"value": "THIS_MONTH",
"type": "INTEGER"
}
],
"columns_set": [
{
"order": 1,
"label": "Code",
"key": "product_code",
"type": "INTEGER"
}
],
"group_by_set": [
{
"order": 1,
"label": "Type",
"key": "product_type",
"type": "TEXT"
}
]
}
HTTP/1.1 200 OK
Schedule a report to be send on a recurring basis and send to users of a specific team
POST https://sandbox.crm.com/backoffice/v1/reports/contacts_summary HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"format": "PDF",
"filters_set": [
{
"label": "Registration date",
"key": "period_from",
"value": "THIS_MONTH",
"type": "TEXT"
}
],
"columns_set": [
{
"order": 1,
"label": "Code",
"key": "product_code",
"type": "INTEGER"
}
],
"group_by_set": [
{
"order": 1,
"label": "Type",
"key": "product_type",
"type": "INTEGER"
}
],
"scheduler_options": {
"period": "MONTHLY",
"frequency": "0 0 12 * * ?"
},
"recipients": [
{
"recipient_type": "TEAM",
"recipient_id": "b52f4dbb-0ccf-db7a-93b6-2cc35af9fc39"
}
]
}
HTTP/1.1 200 OK
{id}
Schedule a report and sends its results via email to a group of recipients
Path variables
The report (identifier) that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The report’s format
Defines the scheduler settings that will send a report on a recurring basis (if not specified, report will be generated and send only once)
Defines the period when report generation will take place
The repeat frequency provided as a cron expression pattern
Defines the recipients that will receive the report results (if not specified, will be send to the user that requested such report)
The type of recipients that will retrieve the report
Applicable only to Business organisations
The recipients that will retrieve the report
Responses
Body
The report identifier
PUT https://sandbox.crm.com/backoffice/v1/reports/81228876-09c6-cc46-638d-be2a7a6867bf HTTP/1.1
Content-Type: application/json
{
"format": "CSV",
"scheduler_options": {
"period": "DAILY",
"frequency": "0 0 12 * * ?"
},
"recipients": [
{
"recipient_type": "USER",
"recipient_id": "b52f4dbb-0ccf-db7a-93b6-2cc35af9fc39"
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "81228876-09c6-cc46-638d-be2a7a6867bf"
}
{id}
Delete a scheduled report
Path variables
The report (unique name) that will be scheduled
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
DELETE https://sandbox.crm.com/backoffice/v1/reports/1193d47e-f079-3f03-299b-50b7419459af HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Retrieve all scheduled reports
Request parameters
Filter based on report name
Filter based on report type
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The type of the event
The scheduled report name
Defines the scheduler settings that will send a report on a recurring basis (if not specified, report will be generated and send only once)
Defines the period when report generation will take place
The repeat frequency provided as a cron expression pattern
The next scheduled period to run the report
Defines the recipients that will receive the report results
The type of recipients that will retrieve the report
Applicable only to Business organisations
The recipient name
The recipient username (applicable for recipients of type == USER)
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/reports HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"type": "contacts_summary",
"name": "VIP Contacts",
"scheduler_options": {
"period": "DAILY",
"next_scheduled": 1631182104
},
"recipients": [
{
"type": "TEAM",
"name": "John Doe",
"username": "johndoe@crm.com"
}
]
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
Get details for a specific (scheduled) report
Path variables
The (scheduled) report (identifier) that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The (scheduled) report (identifier) that will be retrieved
The scheduled report name
The type of the event
The report’s format
Details about the filters based on which the report runs
The filter’s label
The filter’s name
The filter’s value as this was specified by the user
The data type of the filter
Details about the columns that will be included in the report
The ordering of the columns from left to right
The column’s label as this will be displayed on the report
The field’s name
The data type of the filter
Details about the fields to be used to group the report’s results
The grouping’s ordering
The group by field’s label as this will be displayed on the report
The field’s name
The data type of the filter
Defines the scheduler settings that will send a report on a recurring basis (if not specified, report will be generated and send only once)
Defines the period when report generation will take place
The repeat frequency provided as a cron expression pattern
The next scheduled period to run the report
Details about the recipients that will receive the report results
The type of recipients that will retrieve the report
Applicable only to Business organisations
The recipients that will retrieve the report
GET https://sandbox.crm.com/backoffice/v1/reports/df97fe77-84f0-d761-39d6-6d9e1ddf4962 HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"name": "VIP Contacts",
"type": "contacts_summary",
"format": "PDF",
"filters_set": [
{
"label": "Registration date",
"key": "period_from",
"value": "THIS_MONTH",
"type": "DATE"
}
],
"columns_set": [
{
"order": 1,
"label": "Code",
"key": "product_code",
"type": "TEXT"
}
],
"group_by_set": [
{
"order": 1,
"label": "Type",
"key": "product_type",
"type": "TEXT"
}
],
"scheduler_options": {
"period": "MONTHLY",
"frequency": "0 0 12 * * ?"
},
"recipients": [
{
"recipient_type": "TEAM",
"recipient_id": "b52f4dbb-0ccf-db7a-93b6-2cc35af9fc39"
}
]
}
{id}
/analyticsGet analytics for an organisation
Path variables
The organisation identifier that is optionally a parent. If the organisation is a Parent an optional paramter can request children in the same response.
Request parameters
Which metrics are required. A list of metrics can be included in the request, comma separated. At least one must be specified.
Total Awarded Amount and Total Number of Awards and Previous Period Values
Total Spent Amount and Total Number of Spends and Previous Period Values
Frequency denotes which metric will be applied for example get the daily or monthly metrics
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The number of contacts auth’d against a WiFi platform
The number of devices auth’d against a WiFi platform
Details about data allowance (data should be aggregated from child organisations as well)
The consumed data allownace
The remaining data allownace
The total data allownace (consumed + remaining)
Details about the top 10 organisations that allowance was consumed
The organisation identifier
The organisation name
The total allowance consumed on the organisation
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/organisations/babc8d45-50be-4259-b1bf-c85dee46642f/analytics HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "",
"organisation_id": "64824e45-ad64-40c5-9ef4-81cb4d88d9b5",
"organisation_name": "Subscription-Billing",
"merchants": 1,
"venues": 1,
"trials": 1,
"new_sign_ups": 1,
"referred_by": 1,
"reward_participants": 1,
"reward_participants_per_tier": 1,
"open_loop_reward_participants": 1,
"close_loop_reward_participants": 1,
"active_offers": 1,
"most_awarded_offer": "",
"total_awards": 1,
"total_spends": 1,
"given_awards": 1,
"awards_spend": 1,
"average_spend_per_visit": 1,
"top_10_best_offers": [
{
"offer_id": "034de72f-2006-4a80-ba49-13c4de5cc31b",
"offer_name": "Register to Sports channel and win 21 BDT",
"total_award_amount": 26.25
}
],
"total_purchase_amount": 1,
"total_visits": 1,
"most_visited_venues": "",
"total_applications_usage": 1,
"wallets_open_balance": 1,
"wallets_commerse_balance": 1,
"active_subscribers": 1,
"inactive_subscribers": 1,
"new_services": 1,
"cancelled_services": 1,
"regretted_services": 1,
"upgraded_services": 1,
"downgraded_services": true,
"services_in_trial": 1,
"deactivated_services": 1,
"activated_services": 1,
"paid_services_in_trial": 1,
"cancelled_services_in_trial": 1,
"new_subscribers": 1,
"reactivated_subscriptions": 1,
"removed_services_after_expiration": 1,
"cancelled_services_in_contract": 1,
"cancelled_services_not_in_contract": 1,
"renewed_services": 1,
"expired_services": 1,
"subscriber_churn_rate": 1,
"active_subscriptions_per_billing_period": 1,
"active_services_per_month": 1
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
/analyticsGet analytics for a contact
Path variables
The contact (identifier) of which analytics will be retrieved
Request parameters
Filters based on which metrics will be retrieved (a list of metrics can be included in the request, comma separated - and at least one metric should be specified)
Frequency denotes which metric will be applied for example get the daily or monthly metrics
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
Details about the contact
The contact identifier
The contact (full) name
Details about contact’s usage
The usage that is already consumed
The remaining usage that can be consumed
The percentage relation between consumed and allowed usage
GET https://sandbox.crm.com/backoffice/v1/contacts/babc8d45-50be-4259-b1bf-c85dee46642f/analytics?metrics=USAGE&frequency=OVERALL HTTP/1.1
api_key: 4dc0809f-ed91-4b68-b912-5bd6064d901e
HTTP/1.1 200 OK
Content-Type: application/json
{
"contact": {
"id": "fa3360fa-a246-7d1e-1c41-eda3c093dcc9",
"name": "John R. Doe"
},
"usage": {
"consumed_usage": 20,
"remaining_usage": 80,
"usage_percentage": 20
}
}
Create an upload signature for files
Notes
Uploading files into CRM is made based on the following flow & API calls
- Upload File Signature
- Connect File to a “Module” Entity, such as Service Request Files
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
File contents provided via multipart/form-data
Responses
Body
The file identifier that will be used for connecting the file with a module
POST https://sandbox.crm.com/backoffice/v1/upload/files HTTP/1.1
Content-Type: multipart/form-data
api_key: 4dc0809f-ed91-4b68-b912-5bd6064d901e
{
"file": "file object"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "7279fecf-b0a6-0aab-6bcd-37881fe8c10e"
}
{id}
Delete an existing file
Path variables
The file (identifier) to be deleted
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
DELETE https://sandbox.crm.com/backoffice/v1/files/5f21680e-2ce4-7b4b-7221-42cc2a41bc05 HTTP/1.1
api_key: 4dc0809f-ed91-4b68-b912-5bd6064d901e
HTTP/1.1 200 OK
{id}
Retrieve a specific file
Path variables
The file (identifier) to be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The file identifier
The URL that can be used to access the actual content of the file
The mime type of the uploaded file
GET https://sandbox.crm.com/backoffice/v1/files/5f21680e-2ce4-7b4b-7221-42cc2a41bc05 HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "3ae9d64a-8a3b-f1e1-eed6-05b307f926fb",
"content_url": "crm.com/file",
"mime": "txt"
}
{id}
Create an upload media
Notes
Uploading media into CRM is made based on the following flow & API calls
- Create new Media Group
- Create “Module” Media Group, such as Product Media Groups
- Upload Media
- Perform Cloudinary Upload (where CRM will send all signature details)
- Cloudinary service calls back CRM media group (using an internal callback)
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The media group (identifier) to associate the media item with once uploaded (external id is based on the response of Create new Media Group)
Information about the creative type
Partner logos configurable by SO, applicable for Business, Merchant, Venue
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
The related Cloudinary folder (within CRM the folder is set as the media related organisation-id)
The key to track upload (random UUID)
Responses
Body
The API key that is used for uploading media
The name of the cloudinary instance
The uploaded signature context
The uploaded signature value
The date/time on which such upload was made
Details about the upload options
The folder in which media will be uploaded (and located)
The media group external identifier
Information about the creative type
Partner logos configurable by SO, applicable for Business, Merchant, Venue
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Defines how media will be used
The option type (defaults to upload)
Details that will be used in the signature
The folder in which media will be uploaded (and located)
Defines what action will be performed on the media (always is set to “upload”)
The key to track the current upload
POST https://sandbox.crm.com/backoffice/v1/upload/media HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"media_group_external_id": "e66896ba-db0a-41e2-8093-9aca2ae02f29",
"media_usage_type": "LOGO",
"folder": "offers/hero",
"tracking_key": "26c32dfe-f8ea-9cf3-a5af-5096be4a164b"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"api_key": "698271538719998",
"cloud_name": "crm-com",
"context": "uploadStrategy=MEDIA_UPLOAD|organisationId=8062c26a-c05f-47ca-81e4-566b3c279320|trackingKey=e3ffca89-902f-4bd6-b503-c7dcf59dd725|mediaGroupExternalId=1d7b73d2-a324-4cee-a97a-492050b101ef|usageType=ATTACHMENT",
"signature": "8f38472a40d8466f11852bd9d3a19c23bfe12f91",
"timestamp": 1616056261,
"upload_options": [
{
"folder": "35d7d0a4-9846-73a7-8707-26d2507edc51",
"media_group_external_id": "35d7d0a4-9846-73a7-8707-26d2507edc51",
"media_usage_type": "MARKETING",
"options": {
"type": "upload"
},
"needed_signature_options": {
"folder": "6ff2469c-e473-e370-c86e-16633434607a",
"type": "upload"
},
"tracking_key": "6ff2469c-e473-e370-c86e-16633434607a"
}
]
}
{id}
Delete an existing media
Path variables
The media (identifier) to be deleted
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
DELETE https://sandbox.crm.com/backoffice/v1/media/5f21680e-2ce4-7b4b-7221-42cc2a41bc05 HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Create a new group for upcoming uploaded media
Notes
Uploading media for an entity requires the execution of the following APIs
- Create new Media Group
- Create “Module” Media Group, such as Product Media Groups
- Upload Signature
- Perform Cloudinary Upload (where CRM will send all signature details)
- Cloudinary service calls back CRM media group (using an internal callback)
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The media group name
The media group description
The media group external identifier
Responses
POST https://sandbox.crm.com/backoffice/v1/media_group HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"name": "Marketing",
"description": "Marketing Media Group for Creatives",
"externalId": "747e5a96-24a2-7aca-7b28-da5e996ad54c"
}
HTTP/1.1 200 OK
Create an upload signature
Notes
Uploading media into CRM is made based on the following flow & API calls
- Create new Media Group
- Create “Module” Media Group, such as Product Media Groups
- Upload Signature
- Perform Cloudinary Upload (where CRM will send all signature details)
- Cloudinary service calls back CRM media group (using an internal callback)
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The media group (identifier) to associate the media item with once uploaded (external id is based on the response of Create new Media Group)
Information about the creative type
Partner logos configurable by SO, applicable for Business, Merchant, Venue
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
The related Cloudinary folder (within CRM the folder is set as the media related organisation-id)
The key to track upload (random UUID)
Responses
Body
The API key that is used for uploading media
The name of the cloudinary instance
The uploaded signature context
The uploaded signature value
The date/time on which such upload was made
Details about the upload options
The folder in which media will be uploaded (and located)
The media group external identifier
Information about the creative type
Partner logos configurable by SO, applicable for Business, Merchant, Venue
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
The key to track the current upload
POST https://sandbox.crm.com/backoffice/v1/upload/sign HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"mediaGroupExternalId": "e66896ba-db0a-41e2-8093-9aca2ae02f29",
"mediaUsageType": "AVATAR",
"folder": "a01ad9a4-5c9f-e676-fbcb-b0d03c51f022",
"trackingKey": "a01ad9a4-5c9f-e676-fbcb-b0d03c51f044"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"apiKey": "698271538719998",
"cloudName": "crm-com",
"context": "uploadStrategy=MEDIA_UPLOAD|organisationId=8062c26a-c05f-47ca-81e4-566b3c279320|trackingKey=e3ffca89-902f-4bd6-b503-c7dcf59dd725|mediaGroupExternalId=1d7b73d2-a324-4cee-a97a-492050b101ef|usageType=ATTACHMENT",
"signature": "8f38472a40d8466f11852bd9d3a19c23bfe12f91",
"timestamp": 1616056261,
"uploadOptions": [
{
"folder": "35d7d0a4-9846-73a7-8707-26d2507edc51",
"mediaGroupExternalId": "35d7d0a4-9846-73a7-8707-26d2507edc51",
"mediaUsageType": "ATTACHMENT",
"options": {
"type": "upload"
},
"optionsNeededInSignature": {
"folder": "6ff2469c-e473-e370-c86e-16633434607a",
"type": "upload"
},
"trackingKey": "6ff2469c-e473-e370-c86e-16633434607a"
}
]
}
{id}
{id}
{id}
{id}
/actions{id}
/actionsCreate a new automation
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The automation name
The automation description
The automation state
Defines the entity that its events will trigger this automation
Defines the event that will trigger this automation (filtered based on the selected entity)
Approvals
Approvals
Contacts
Contacts
Contacts
ContactsContacts
Contacts
Contacts & Users
Orders
Orders
Orders
Orders
Passes
Passes
Rewards
Rewards
Reward Offers
Reward Schemes
Service Requests
Organisations
Organisations
Users
Users
Products
Financial Transactions
Financial Transactions
Financial Transactions
Financial Transactions
Financial Transactions
Customer Events
Customer Events
Customer Events
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Financial Transactions
Responses
The requested succeded
Body
The automation identifier
POST https://sandbox.crm.com/backoffice/v1/automations HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"name": "Approve Offers",
"description": "Require 4 approvals for an offer",
"state": "INACTIVE",
"entity": "ORDERS",
"event": "ORDER_INITIATION"
}
HTTP/1.1 201 Created
Content-Type: application/json
{
"id": "890108f6-0237-d984-a367-2f9502dc2acc"
}
{id}
Update an existing automation
Path variables
The automation (identifier) that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The automation name
The automation description
Defines whether the automation is active or not
Responses
Successful Request
Body
The automation identifier that was updated
PUT https://sandbox.crm.com/backoffice/v1/automations/QWERTY1234543212345678UJIKY76HJR HTTP/1.1
Content-Type: application/json
{
"name": "Approve Offers",
"description": "Require 4 approvals for an offer",
"life_cycle_state": "ACTIVE"
}
{id}
Delete an existing automation
Path variables
The automation (identifier) that will be deleted
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Successful Request
DELETE https://devapi.crm.com/backoffice/v1/automations/QWERTY1234543212345678UJIKY76HJR HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
Search for automations
Request parameters
Search automations based on Name
Filter based on automation name
Filter based on automation state
Filter based on the entity that its event will trigger the automation
Filter based on the event that will trigger the automation
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The automation identifier
The automation name
The automation description
The automation state
Defines the entity that its events will trigger this automation
Defines the event that will trigger this automation (filtered based on the selected entity)
Approvals
Approvals
Contacts
Contacts
Contacts
ContactsContacts
Contacts
Contacts & Users
Orders
Orders
Orders
Orders
Passes
Passes
Rewards
Rewards
Reward Offers
Reward Schemes
Service Requests
Organisations
Organisations
Users
Users
Products
Financial Transactions
Financial Transactions
Financial Transactions
Financial Transactions
Financial Transactions
Customer Events
Customer Events
Customer Events
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Financial Transactions
The page number
The number of records per page
The overal number of records
GET https://stagingapi.crm.com/backoffice/v1/automations HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"name": "Notify customers on award",
"description": "Lorem Ipsum",
"life_cycle_state": "INACTIVE",
"entity": "Contacts",
"event": "Register Customer"
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
Get details for a specific automation
Path variables
The automation (identifier) that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The automation identifier
The automation name
The automation description
The automation state
Defines the entity that its events will trigger this automation
Defines the event that will trigger this automation (filtered based on the selected entity)
Approvals
Approvals
Contacts
Contacts
Contacts
ContactsContacts
Contacts
Contacts & Users
Orders
Orders
Orders
Orders
Passes
Passes
Rewards
Rewards
Reward Offers
Reward Schemes
Service Requests
Organisations
Organisations
Users
Users
Products
Financial Transactions
Financial Transactions
Financial Transactions
Financial Transactions
Financial Transactions
Customer Events
Customer Events
Customer Events
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Subscriptions
Financial Transactions
GET https://devapi.crm.com/backoffice/v1/automations/CEEE83D6E0804A30966F684B0269AD91 HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"name": "Notify awarded customers",
"description": "On customer award an outbound email communication will be triggered",
"life_cycle_state": "INACTIVE",
"entity": "CONTACTS",
"event": "AWARD_CUSTOMER"
}
{id}
/actionsSet the sequence of actions (including filters) for a specific automation
Path variables
The automation (identifier) whose sequence will be set
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The automation action identifier
Defines the sequence’s action
Defines the sequence path
The automation adaptor
Approval Requests
Automatic Content Updates
Communications
Order Provision
Service Request Provision
Webhooks
MICROS Simphony Order Provision
NCR Aloha Order Provision
The automation adaptor action (each action is applicable for specific adaptors)
Request User Appoval (Approval Requests adaptor)
Request Customer Appoval (Approval Requests adaptor)
Update Content (Automatic Content Updates adaptor)
Communicate Customer (Communications adaptor)
Communicate User (Communications adaptor)
Assign To A Specific User (Order Provision & Service Request Provision adaptor)
Fulfilled By Specific Organisation (Order Provision & Service Request Provision adaptor)
Assign To Specific Team (Order Provision adaptor)
Fulfilled By Nearest Location (Order Provision adaptor)
Fulfilled Based On Post Code Coverage (Order Provision adaptor)
POST Webhook (webhooks adaptor)
Put Webhook (webhooks adaptor)
Assign To User Of A Specific Team (Service Request Provision adaptor)
Assign To User Of A Specific User Role (Service Request Provision adaptor)
Fulfilled By User Of A Specific User Role (Service Request Provision adaptor)
Fulfilled By Specific User (Service Request Provision adaptor)
Provision Order To Simphony POS (MICROS Simphony Order Provision adaptor)
Provision Order To Aloha POS (NCR Aloha Order Provision adaptor)
Details about the adaptor’s actions parameters
The parameter identifier
The parameter group (used when more than one parameters should be specified for an adaptor’s action)
The parameter key
The parameter from value
The parameter to value
The parameter type
Details about the filters to be applied (required when type is based on Filter)
Details about the applicable filtered attributes
The filter identiifer
The custom field that its value will be compared based on the related operator
The attribute that its value will be compared based on the related operator
The type of the key
The filter operator to compare the attribute actual value with the filtered one
Applicable for type of number/integer/date
Applicable for type of string
Applicable for type of number/integer/date
Applicable for type of number/integer/date
Applicable for type of number/integer/date
Applicable for type of number/integer/date
The attribute value to apply the filter condition (either value or value_list should be specified)
The supported list of values (either value or value_list should be specified)
Responses
OK
Body
The automation identifier
POST https://stagingapi.crm.com/backoffice/v1/automations/6A24D2B5E44F44B28451FE021FCAD51E/actions HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"content": [
{
"id": "ACTIONB5E44F44B28451FE021FCAD51E",
"adaptor": "APPROVAL_REQUESTS",
"adaptor_action": "ASSIGN_SPECIFIC_DEPARTMENT",
"order": 1,
"path": "1",
"adaptor_action_parameters": [
{
"id": "4b8e0ae7-0f8a-4313-a1fd-ecc1c0510f55",
"parameter_group": "1",
"parameter_key": "RICH_CONTENT",
"parameter_from_value": "123",
"parameter_to_value": "1234",
"parameter_type": "APPROVAL_ENTITY_TYPE"
}
],
"action_filters": [
{
"filters": [
{
"id": "edd5ac0e-05e3-e543-d38e-c6df6eed8d46",
"attribute": "NAME",
"type": "NUMBER",
"operator": "EQUAL_LESS",
"value": "123",
"value_list": [
""
]
}
]
}
]
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "6A24D2B5E44F44B28451FE021FCAD51E"
}
{id}
/actionsRetrieves the automation’ sequence of actions (including filters)
Path variables
The automation (identifier) whose actions will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
The automation action identifier
Defines the sequence’s action
The automation adaptor
Approval Requests
Automatic Content Updates
Communications
Order Provision
Service Request Provision
Webhooks
MICROS Simphony Order Provision
NCR Aloha Order Provision
The automation adaptor action (each action is applicable for specific adaptors)
Request User Appoval (Approval Requests adaptor)
Request Customer Appoval (Approval Requests adaptor)
Update Content (Automatic Content Updates adaptor)
Communicate Customer (Communications adaptor)
Communicate User (Communications adaptor)
Assign To A Specific User (Order Provision & Service Request Provision adaptor)
Fulfilled By Specific Organisation (Order Provision & Service Request Provision adaptor)
Assign To Specific Team (Order Provision adaptor)
Fulfilled By Nearest Location (Order Provision adaptor)
Fulfilled Based On Post Code Coverage (Order Provision adaptor)
POST Webhook (webhooks adaptor)
Put Webhook (webhooks adaptor)
Assign To User Of A Specific Team (Service Request Provision adaptor)
Assign To User Of A Specific User Role (Service Request Provision adaptor)
Fulfilled By User Of A Specific User Role (Service Request Provision adaptor)
Fulfilled By Specific User (Service Request Provision adaptor)
Provision Order To Simphony POS (MICROS Simphony Order Provision adaptor)
Provision Order To Aloha POS (NCR Aloha Order Provision adaptor)
Details about the adaptor’s actions parameters
The parameter identifier
The parameter key
The parameter from value
The parameter to value
The parameter type
The parameter group (used when more than one parameters should be specified for an adaptor’s action)
Details about the filters to be applied (required when type is based on Filter)
Details about the applicable filtered attributes
The filter identiifer
The attribute that its value will be compared based on the related operator
The type of the key
The filter operator to compare the attribute actual value with the filtered one
Applicable for type of number/integer/date
Applicable for type of string
Applicable for type of number/integer/date
Applicable for type of number/integer/date
Applicable for type of number/integer/date
Applicable for type of number/integer/date
The attribute value to apply the filter condition (either value or value_list should be specified)
The supported list of values (either value or value_list should be specified)
The custom field that its value will be compared based on the related operator
GET https://stagingapi.crm.com/backoffice/v1/automations/6A24D2B5E44F44B28451FE021FCAD51E/actions HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "ACTIONB5E44F44B28451FE021FCAD51E",
"order": 1,
"adaptor": "COMMUNICATIONS",
"adaptor_action": "REQUEST_APPROVAL",
"adaptor_action_parameters": [
{
"id": "4b8e0ae7-0f8a-4313-a1fd-ecc1c0510f55",
"parameter_key": "RICH_CONTENT",
"parameter_from_value": "123",
"parameter_to_value": "1234",
"parameter_type": "SUPPLY_METHOD",
"parameter_group": "1"
}
],
"action_filters": [
{
"filters": [
{
"id": "edd5ac0e-05e3-e543-d38e-c6df6eed8d46",
"attribute": "NAME",
"type": "NUMBER",
"operator": "GREATER",
"value": "123",
"value_list": [
""
]
}
]
}
]
}
]
}
{id}
/actions/{action_id}
/records/{record_id}
{id}
/actions/{action_id}
/records{id}
/actions/{action_id}
/records/{record_id}
{id}
/actions/{action_id}
/records/{record_id}
Change the value of a specific adaptor action record attribute
Path variables
The approval request (identifier) that will be updated
The action (identifier) whoe record will be retrieved
The record (identifier) that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The record’s key
The record’s value
Responses
Successful Request
Body
The record identifier
POST https://stagingapi.crm.com/backoffice/v1/adaptors/CAD1E31269B76D7A65ACCE45B2E68DFD/actions/CAD1E31269B76D7A65ACCE45B2E68DFQ/records/CAD1E31269B76D7A65ACCE45B2E68DFJ HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"key": "url-endpoint",
"value": "https://crm.com"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
/actions/{action_id}
/recordsSearch for an adaptor action’s records (e.g. CRM.COM Apporvals Adaptor approval requests)
Path variables
The adaptor (identifier) whose actions will be retrieved
The action (identifier) that will be retrieved
Request parameters
Defines the entitiy type that the search will be applied (required for search_value)
Defines the free text search parameter based on the provided type (required when search_type is specified)
Filter based on automations that triggered such action
Filter based on adapto action that created such record
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The record identifier
Details about the records attributes
The attribute identifier
The record’s attribute key
The record’s attribute label
The record’s attribute type
The record’s attribute value
The page number
The number of records per page
The overal number of records
GET https://stagingapi.crm.com/backoffice/v1/adaptors/82697d43-4970-4dcc-bd35-7df27c72b8f6/actions/1b75a53f-b189-40bb-8db0-39b0578a6aqa/records HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"record_attributes": [
{
"id": "CEEE83D6E0804A30966F684B0269AD9G",
"key": "url-endpoint",
"label": "URL Endpoint",
"type": "string",
"value": "https://crm.com"
}
]
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
/actions/{action_id}
/records/{record_id}
Retrieve details for a specifc adaptor action’s records (e.g. CRM.COM WEbhooks Adaptor webhook request)
Path variables
The adaptor (identifier) whose action’s record will be retrieved
The action (identifier) whoe record will be retrieved
The record (identifier) that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The record identifier
Details about the record attributes
The attribute identifier
The record’s attribute key
The record’s attribute label
The record’s attribute type
The record’s attribute value
GET https://stagingapi.crm.com/backoffice/v1/adaptors/82697d43-4970-4dcc-bd35-7df27c72b8f6/actions/1b75a53f-b189-40bb-8db0-39b0578a6aqa/records/1b75a53f-b189-40bb-8db0-39b0578a6a2w HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "be8c05c4-2f97-4b40-a979-42f066db265c",
"record_attributes": [
{
"id": "be8c05c4-2f97-4b40-a979-42f066db26qw",
"key": "url-endpoint",
"label": "URL Endpoint",
"type": "string",
"value": "https://crm.com"
}
]
}
{id}
/actionsSearch for approval requests
Request parameters
The value of the search (case insensitive) across entity and entity reference
Filter based on approval request state
Filter based on automations that triggered such request (applicable only when org_requests is set to NETWORK_REQUESTS)
Filter based on a single user that is authorised to approve/reject such request
Filter based on a single contact that is authorised to approve/reject such request
Filter based on the condition type that are authorised to approve/reject such requests
Filter based on the entity (contact/user) that requested such approval
Filter based on the entity type that such requests are applied to
Filter based on entity record that such request is applied to
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The approval request identifier
The approval request state
Details about the entity that such approval request was applied to
The entity identifier
The approval entity type
The entity reference name/code/number
Details about the automation
The automation identifer
The automation name
Details about the approval request’s response
The authorised user/contact response message on this request
The resposne state
Details about the person (user/contact) who approved/rejected such request
The authorised person identifier
The authorised person full name
The authorised type of person
The date/time when such request was approvded/rejected
Details about the authorised by type who can approve/reject such requests
The authorised condition identifier
The authorised condition name (e.g. contact full name, user role name)
The authorised condition type
The date that the approval was requested
Defines how many should approve/reject the approval
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/approval_requests HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"state": "APPROVED",
"description": "The award of the offer has been changed to 100% from what it was 50%",
"response": "Approved",
"authorised_by": {
"id": "23490b97-dd93-3eb4-c3bc-e6828e12e2c1",
"name": "John Doe",
"type": "USER"
},
"authorised_on": 1611930210,
"automations": {
"id": "cf010c72-a2cb-48f8-a9fa-1ed99c8d6ec0",
"name": "Request approval on newly activated offers"
},
"entity": {
"id": "cf010c72-a2cb-48f8-a9fa-1ed99c8d6ec0",
"type": "REWARD_OFFER",
"reference": "5% discount"
},
"authorised_conditions": [
{
"id": "18eb40c8-ba71-fa51-9de7-5b7017962ccf",
"name": "John Doe",
"type": "USER"
}
]
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
/actionsChange the life cycle state of a single approval request
Path variables
The approval request identifier that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The approval request state that will be changed to
The reason why the approval request was approved or rejected
Responses
Successful Request
Body
The approval request identifier
POST https://devapi.crm.com/backoffice/v1/approval_requests/CAD1E31269B76D7A65ACCE45B2E68DFD/life_cycle_state HTTP/1.1
Content-Type: application/json
{
"life_cycle_state": "REJECTED"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
Retrieve the pending approvals that the signed-in user is authorised to approve/reject, but not yet process them
Request parameters
The value of the search (case insensitive) across entity and entity reference
Filter based on the entity type that such requests are applied to
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
Responses
The request has succeeded
Body
The approval request identifier
Details about the entity that such approval request was applied to
The entity identifier
The approval entity type
The entity reference name/code/number
Details about the automation
The automation identifer
The automation name
The date that the approval was requested
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/approval_requests/my_pending_approvals HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"entity": {
"id": "cf010c72-a2cb-48f8-a9fa-1ed99c8d6ec0",
"type": "SERVICE_REQUEST",
"reference": "CO1234"
},
"automations": {
"id": "cf010c72-a2cb-48f8-a9fa-1ed99c8d6ec0",
"name": "Request approval on newly activated offers"
},
"created_date": 1642508197
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
Retrieve the approvals requested by the signed-in user
Request parameters
The value of the search (case insensitive) across entity and entity reference
Filter based on approval request state
Filter based on the entity type that such requests are applied to
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
Responses
The request has succeeded
Body
The approval request identifier
The approval request state
Details about the entity that such approval request was applied to
The entity identifier
The approval entity type
The entity reference name/code/number
Details about the automation
The automation identifer
The automation name
Details about the approval request’s response
The authorised user/contact response message on this request
The resposne state
Details about the person (user/contact) who approved/rejected such request
The authorised person identifier
The authorised person full name
The authorised type of person
The date/time when such request was approvded/rejected
The date that the approval was requested
Defines how many should approve/reject the approval
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/approval_requests/my_requests HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CEEE83D6E0804A30966F684B0269AD91",
"state": "APPROVED",
"entity": {
"id": "cf010c72-a2cb-48f8-a9fa-1ed99c8d6ec0",
"type": "ORDER",
"reference": "CO1234"
},
"automations": {
"id": "cf010c72-a2cb-48f8-a9fa-1ed99c8d6ec0",
"name": "Request approval on newly activated offers"
},
"responses": [
{
"message": "This is a response message",
"state": "APPROVED",
"authorised_by": {
"id": "23490b97-dd93-3eb4-c3bc-e6828e12e2c1",
"name": "John Doe",
"type": "USER"
},
"authorised_on": 1611930210
}
],
"created_date": 1642508197,
"pending_requests": 2
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
{id}
{id}
Create a new webhook
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The webhook name
The webhook method type
The webhook url endpoint
Defines how the webhook will be protected
The username that will auth the webhook requests (applicable if url_auth = USERNAME_PASSWORD)
The password that will auth the webhook requests (applicable if url_auth = USERNAME_PASSWORD)
The api key that will auth the webhook requests (applicable if url_auth = API_KEY)
Number of times to retry
Wait for period before retry (in seconds)
Responses
OK
Body
The webhook identifier
POST https://stagingapi.crm.com/backoffice/v1/webhooks HTTP/1.1
Content-Type: application/json
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
{
"name": "CRMdotCOM Delivery",
"method": "POST",
"url_endpoint": "https://crm.com/delivery",
"url_auth": "NO_AUTH",
"username": "johndoe",
"password": "crm.com",
"api_key": "qwert-12345-qwewerwer-123234234-werwerwr"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "API1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
Update an existing webhook
Path variables
The webhook (identifier) that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The webhook name
The webhook url endpoint
Defines how the webhook will be protected
The username that will auth the webhook requests (applicable if url_auth = USERNAME_PASSWORD)
The password that will auth the webhook requests (applicable if url_auth = USERNAME_PASSWORD)
The api key that will auth the webhook requests (applicable if url_auth = API_KEY)
Number of Times to Retry
Wait for period before retry (in seconds)
Responses
OK
Body
The webhook identifier
PUT https://devapi.crm.com/backoffice/v1/webhooks/CAD1E31269B76D7A65ACCE45B2E68WHI HTTP/1.1
Content-Type: application/json
authorization: 4AD9C84FA60F9FE407140E20F707726A
{
"name": "CRMdotCOM Delivery",
"url_endpoint": "https://crm.com/delivery",
"url_auth": "NO_AUTH",
"username": "johndoe",
"password": "crm.com",
"api_key": "qwert-12345-qwewerwer-123234234-werwerwr"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "API1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
Delete an existing webhook
Path variables
The webhook (identifier) that will be deleted
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
DELETE https://devapi.crm.com/backoffice/v1/webhooks/CAD1E31269B76D7A65ACCE45B2E68WHI HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
Retrieve all webhooks
Request parameters
The value of the search (case insensitive) across Name, URL Endpoint
Filter based on the name
Filter based on the url endpoint
Filter based on related automation entity
Filter based on related automation event
Filter based on whether webhook has at least one failed request
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
Information about the organisation’ webhooks
The webhook identifier
The webhook name
The webhook method type
The webhook url endpoint
Defines how the webhook will be protected
The number of pending requests
The number of successful requests
The number of failed requests
Number of times to retry
Wait for period before retry
The page number
The number of records per page
The overal number of records
GET https://devapi.crm.com/backoffice/v1/webhooks HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "API1E31269B76D7A65ACCE45B2E68DFD",
"name": "Registration Name",
"url_endpoint": "https;//crm.com/delivery",
"url_auth": "API_KEY"
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
Get details of a single webhook
Path variables
The webhooks (identifier) that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
Information about the organisation’ webhooks
The organisation’s webhook identifier
The webhook name
The webhook method type
The webhook url endpoint
Defines how the webhook will be protected
The webhook auth username (applicable only if url_auth = USERNAME_PASSWORD)
The webhook auth password (applicable only if url_auth = USERNAME_PASSWORD)
Defines the date up until the secret api key will be active
The number of pending requests
The number of successfull requests
The number of failed requests
Number of times to retry
Wait for period before retry (in seconds)
GET https://devapi.crm.com/backoffice/v1/webhooks/API1E31269B76D7A65ACCE45B2E68DFD HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "API1E31269B76D7A65ACCE45B2E68DFD",
"name": "CRMdotCOM Delivery",
"url_endpoint": "https://crm.com/delivery",
"url_auth": "USERNAME_PASSWORD",
"username": "johndoe",
"password": "crm.com",
"api_key": "sdfsdfsdf-32423423423-wefsdfsdfdsf-234234234"
}
]
}
Retrieve webhook requests
Request parameters
The value of the search (case insensitive) across Webhook Name, URL Endpoint
Filter based on the webhook
Filter based on the url endpoint
Filter based on the request state
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
Body
Information about the organisation’ webhook requests
The webhook request identifier
The state of the webhook request
The webhook url endpoint
Defines how the webhook will be protected
The request body that was sent
The response that was sent
The total number of request retries
The webhook of the request
The webhook identifier
The webhook name
The automation that triggered the webhook
The automation identifier
The automation name
Information about the related entity that the request is created for
The entity type that the webhook request is created for
The entity’s reference name/code/number
The date that such request was made
The page number
The number of records per page
The overal number of records
GET https://devapi.crm.com/backoffice/v1/webhook_requests HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "API1E31269B76D7A65ACCE45B2E68DFD",
"state": "SUCCESS",
"url_endpoint": "https;//crm.com/delivery",
"url_auth": "USERNAME_PASSWORD",
"body": "POST /crm.com/delivery HTTP/1.1 Host: staging.crm.com Content-Type: application/json api_key: 123456789012-1234-1234-1234-123456789012 Content-Type: text/plain { \"contact_id\": \"123456789012-ABCD-ABCD-ABCD-123456789012\", \"amount\": 20.45 }",
"response": "{ \"status\": { \"code\": \"COM.CRM.EXCEPTION.INVALIDTOKENEXCEPTION\", \"description\": \"The specific token is not valid.\", \"message\": \"The token is invalid, please obtain a new one.\" } }",
"retries": 3,
"webhook": {
"id": "API1E31269B76D7A65ACCE45B2E68WIH",
"name": "CRMdotCOM Delivery"
},
"automation": {
"id": "b63ed1ab-0256-453d-82a4-a8a83a02ea8b",
"name": "Share content to delivery system"
},
"entity": {
"type": "CONTACT",
"reference": "ORD1234ER"
}
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
Resend a number of failed webhook requests
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
List all failed webhook requests that should be resend
Responses
The request has succeeded
{id}
/actionsPreview the content of a file that will be imported
Notes
Importing Data should be made based on the following API order
- Upload File Signature
- Optionally, preview the content of the uploaded file via Import Preview
- Submit a request to import the content of the uploaded file, including a couple behavorial options via Import Data
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The file (identiifer) that will be previewed
Defines the number of rows that will be previewed (header row is excluded)
Defines whether the header row values will be excluded from import or not
Defines the mapping between the imported file attribures and system attributes
The imported file attribute that will be mapped to the system’s one
The system attribute that will be mapped to the imported file’s one
Defines whether the system attribute key is a custom one or not
Responses
Body
Details about the file preview per row
The header attribute of the specific row
The previewed values of the specific row
[
"CRM", "CRMI"
]
GET https://sandbox.crm.com/backoffice/v1/imports/preview HTTP/1.1
Content-Type: application/json
api_key: 4dc0809f-ed91-4b68-b912-5bd6064d901e
{
"file_id": "f56f9cd8-9cb2-bbe6-d4d9-ae14bb1f0399",
"preview_rows": 2
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"header": "Organisation Name",
"values": [
"CRM", "CRMI"
]
},
{
"header": "Organisation Type",
"values": [
"BUSINESS", "VENUE"
]
}
]
}
Submit a request for importing data along with processing options
Notes
Importing Data should be made based on the following API order
- Upload File Signature
- Optionally, preview the content of the uploaded file via Import Preview
- Submit a request to import the content of the uploaded file, including a couple behavorial options via Import Data
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The file (identifier) that will be used for importing data
The type of the entity that data will be imported
Defines whether the header row values will be excluded from import or not
Defines whether existing records will be updated or not
Defines whether missing attributes will be created automatically
Defines the mapping between the imported file attribures and system attributes
The imported file attribute that will be mapped to the system’s one
The system attribute that will be mapped to the imported file’s one
Defines whether the system attribute key is a custom one or not
Responses
Body
The import definition identifier
POST https://sandbox.crm.com/backoffice/v1/imports HTTP/1.1
Content-Type: application/json
{
"file_id": "1e347d4d-ab96-6957-fdb6-35e72b3d9185",
"type": "CONTACTS",
"exclude_header": true,
"update_data": "false",
"auto_generate_config": true,
"data_mapping": [
{
"import_key": "contact first name",
"attribute_key": "first_name",
"is_custom": "false"
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "1e347d4d-ab96-6957-fdb6-35e72b3d9185"
}
Search for import data definitions
Request parameters
Filter imports based on status
Filter imports based on imported record type
Filter based on the imported date, which may fall within a given date range. The value can be a string with a date in epoch format. Each option must also include an operator. Use up to two options based on the required search (e.g. imported_on[gte]=1618395497&imported_on[lt]=1618395497).
Returns results where the imported date is greater than this value
Returns results where the imported date is greater than or equal to this value
Returns results where the imported date is less than this value
Returns results where the imported date is less then or equal to this value
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
Body
The import definition identifier
The export definition status
The type of the entity that data will be imported
The date that such import was made
Details how the import file content will be processed
Defines whether the header row values will be excluded from import or not
Defines whether existing records will be updated or not
Defines whether missing attributes will be created automatically
Details about the uploaded file that was used for import
The file identifier
The file name
Details about the file that contain all failed imported data
The file identifier
The file name
Details about the processed data
The records that were created successfully
The records that were updated successfully
The records that were not changed
The records that were failed to be processed
The total number of records that were imported
The page number
The number of records per page
The overal number of records
GET https://sandbox.crm.com/backoffice/v1/imports HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "507c17d2-3976-d1e5-ccf5-cf3c1334acc7",
"status": "COMPLETED",
"type": "PRODUCTS",
"imported_on": 1623677135,
"options": {
"exclude_header": true,
"update_data": true,
"auto_generate_config": "false"
},
"file": {
"id": "507c17d2-3976-d1e5-ccf5-cf3c1334acc7",
"name": "contacts.csv"
},
"error_file": {
"id": "507c17d2-3976-d1e5-ccf5-cf3c1334acc7",
"name": "contacts_errors.csv"
},
"processed_results": {
"new": 19,
"updated": 4,
"unchanged": 4,
"errors": 1,
"total": 28
}
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
/actionsApply an action on an existing import definition
Path variables
The import definition (identifier) on which an action will be performed
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The type of action that will be performed
Re-submit an import with FAILED status
Responses
Body
The import definition identifier
POST https://sandbox.crm.com/backoffice/v1/imports/0e2e1e37-b118-7bbc-db46-6cd954e01a89/actions HTTP/1.1
Content-Type: application/json
{
"action": "REPLAY"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "0e2e1e37-b118-7bbc-db46-6cd954e01a89"
}
{id}
/network{id}
{id}
{id}
/network{id}
{id}
/activity_feed{id}
/switch{id}
/masquerade{id}
/actions{id}
/media_groups{id}
/billingCreates a business semantic parent as the primary business.
Request headers
The public api key required for API calls to identify the organisation
Request body
The name of the organisation
A brief description of the organisation
The type of the organisation
Defines whether the organisation is the primary business of the business network
The parent organisation identifier that this organisation belongs to
Determines whether the organisation record will be used for test purposes
Determines whether the sandbox mode is enabled or not
Information about the owner (admin user) of the organisation
The user’s first name
The user’s last name
Information about the owner’s identity
The provider of the identity
The identity’s challenge
The identity’s value (e.g. password)
Information about the owner’s contact information
The name of the contact information
The type of the contact information
The contact information value
The country code of the related contact info of type phone
Information about the organisation’s location
Information about the organisation’s location
The name of the location
The address of the location
Additional address information about the location
The state/province/county of the location
The town/city of the location
The postal code of the location
The country code of the location
The care of information of the location
The latitude of the location
The longitude of the location
The Google textual identifier that uniquely identifies a location
The organisation’s base currency (applicable for service owner/business)
The organisation timezone (applicable for business)
The custom field’s unique key
The custom field’s value
Responses
OK
Body
The organisation identifier
POST /organisations/register HTTP/1.1
Content-Type: application/json
api_key: 8c54d563-b991-4b76-8a83-557c08166f95
{
"name": "Delicious Food Group",
"description": "Lorem Ipsum",
"vat_number": "VAT123456789",
"org_type": "BUSINESS",
"is_business": "true",
"organisation_id": "11",
"test_mode": "false",
"is_sandbox_on": "true",
"owner": {
"first_name": "John",
"last_name": "Doe",
"contact_info": [
{
"name": "",
"type": "EMAIL",
"value": "4499885544"
}
]
},
"location": [
{
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"care_of": "",
"lat": "35.157115",
"lon": "33.313719",
"googleplaceid": "ChIJrTLr-GyuEmsRBfy61i59si0"
}
]
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
/networkExpand the business network with new organisations such as transaction processor, service owners and business
Path variables
The organisation (identifier) that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The type of the new organisation
Applicable on the level of a Cloud Operator
Applicable on the level of a Cloud Operator
Applicable on the level of a Service Owner
Applicable on the level of a Business
Applicable on the level of a Business or Merchant
The name of the organisation
A brief description of the organisation
Defines whether the organisation is the primary business of the network
The organisation’s country of agreement code (applicable for service owner/business)
The organisation industry identifier
The organisation industry sectors
The groups of the organisation (only organisation types of Merchant, Venue and Service Point can be grouped)
Information about the owner (admin user) of the organisation
The user’s first name
The user’s last name
Information about the owner’s identity
The provider of the identity
The identity’s challenge
The identity’s value (e.g. password)
Information about the owner’s contact information
The name of the contact information
The type of the contact information
The contact information value
The country code of the related contact info of type phone
Information about the organisation’s contact details
Information about the owner (admin user) of the organisation
The name of the contact information
The type of the organisation’s contact detail
The contact information value
The country code of the related contact detail of type phone
Information about the organisation’s location
Information about the organisation’s location
The name of the location
The address of the location
Additional address information about the location
The state/province/county of the location
The town/city of the location
The postal code of the location
The country code of the location
The care of information of the location
The latitude of the location
The longitude of the location
The Google textual identifier that uniquely identifies a location
Information about the organisation’s transaction acquiring points
Information about the organisation’s external references
The transaction acquiring point name
The transaction acquiring point code
Defines whether the transaction acquiring point is active or not
The transaction acquiring point description
IP address of External Device
Port of the External IP
The transaction acquiring point type
Optional specification of external reference
The organisation business activities
Defines whether the new organisation will have the same industry, industry sectors and business activities as its parent organisation
Details about the organisation profile
The organisation’s registration number
The organisation’s TAX reference number
The organisation’s VAT reference number
The company’s registration country code
The parent organisation identifier that this organisation belongs to
The name that the organisation will have on the cloud (applicable for Service Owner organisations; special characters not allowed)
The tags of the organisation
The organisations (service owners) that the organisation (transaction processor) serves
7c56cc02-48cf-9832-e412-a4ae022cd547
Defins whether organisation will support contact registry or not (applicable for Service Owner, Business, Subsidiary)
The custom field’s unique key
The custom field’s value
Details about provisioning an organisation over to WiFi
The integration identifier that organisation will be provisioned for WiFi
The site identifier that will be used to identify the organisation over to WiFi platform
Responses
OK
Body
The organisation identifier
POST https://sandbox.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD/network HTTP/1.1
Content-Type: application/json
{
"org_type": "VENUE",
"name": "Delicious Food Group",
"description": "Lorem Ipsum",
"is_business": "true",
"country_agreement": "CYP",
"industry_id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"industry_sectors": [
"CAD1E31269B76D7A65ACCE45B2E68DFD"
],
"groups": [
"CAD1E31269B76D7A65ACCE45B2E68DFD"
],
"owner": {
"first_name": "John",
"last_name": "Doe",
"identity": {
"provider": "EMAIL",
"identity_challenge": "jd@crm.com",
"identity_value": "12345"
},
"contact_info": [
{
"name": "",
"type": "EXTENSION",
"value": "4499885544",
"country_code": "CYP"
}
]
},
"contact_info": [
{
"name": "Main Office",
"type": "EMAIL",
"value": "johndoe@deliciousfood.com",
"country_code": "CYP"
}
],
"locations": [
{
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"care_of": "c/o Company",
"lat": 35.157115,
"lon": 33.313719,
"google_place_id": "ChIJrTLr-GyuEmsRBfy61i59si0"
}
],
"taps": [
{
"name": "POS",
"code": "02451",
"is_active": "true",
"description": "pos system",
"external_ip": "82.102.93.164",
"external_port": "9100",
"tap_type": "CARD_TERMINAL",
"external_type": "ALOHA"
}
],
"business_activities": [
"CAD1E31269B76D7A65ACCE45B2E68DFD"
],
"inherit_from_parent": "false",
"organisation_profile": {
"registration_number": "1234",
"tax_reference_number": "TAX1234",
"vat_reference_number": "VAT1234",
"registration_country": "CYP"
},
"organisation_id": "e7251be4-89f2-8cea-7a4a-65b679cf6131",
"cloud_name": "crmdotcom",
"organisation_tags": [
"Accounting"
],
"service_organisations": [
"7c56cc02-48cf-9832-e412-a4ae022cd547"
],
"contact_registry": "true",
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
],
"wifi_platform": {
"integration_id": "88165da9-58a9-74cd-3da5-593b901fc0ec",
"site_id": "88quh2m6"
}
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
Update a single organisation
Path variables
The organisation (identifier) that will be updated
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The name of the organisation
A brief description of the organisation
Information about the organisation’s contact details
The identifier of the organisation’s contact detail
The type of the organisation’s contact detail
The value of the organisation’s contact detail
The name of the organisation’s contact detail
The industry of the organisation
The industry sectors of the organisation
The business activities of the organisation
The groups of the organisation (only organisation types of Merchant, Venue and Service Point can be grouped)
Defines whether the new organisation will have the same industry, industry sectors, business activities and reward tags as its parent organisation
Details about the organisation profile
The organisation’s registration number
The organisation’s TAX reference number
The organisation’s VAT reference number
The company’s registrationc country code
The name that the organisation will have on the cloud (applicable for Service Owner organisations; special characters not allowed)
The tags of the organisation
The organisations (service owners) that the organisation (transaction processor) serves
1daf80b1-134b-36eb-7146-76dec04e6c5d
Defines whether organisation supports contact registry or not
Information about the organisation’s location
The location identifier that will be updated
The name of the location
The address of the location
Additional address information about the location
The state/province/county of the location
The town/city of the location
The postal code of the location
The country code of the location
The care of information of the location
The latitude of the location
The longitude of the location
The Google textual identifier that uniquely identifies a location
The custom field’s unique key
The custom field’s value
Defines the partners (their logos will appear on the backend) assigned on this organisation by the service owner. applicable only for organisations of BUSINESS type
The partner identifier
The billing business identifier
The default service identifier
Responses
OK
Body
The organisation identifier
PUT https://sandbox.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD HTTP/1.1
Content-Type: application/json
{
"name": "Delicious Food Group",
"description": "Lorem Ipsum",
"contact_info": [
{
"id": "CK1234567890123456789012345678",
"type": "PHONE",
"value": "info@crm.com",
"name": "Head Office"
}
],
"industry_id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"industry_sectors": [
"CAD1E31269B76D7A65ACCE45B2E68DFD"
],
"business_activities": [
"CAD1E31269B76D7A65ACCE45B2E68DFD"
],
"groups": [
"CAD1E31269B76D7A65ACCE45B2E68DFD"
],
"inherit_from_parent": "false",
"organisation_profile": {
"registration_number": "1234",
"tax_reference_number": "TAX1234",
"vat_reference_number": "VAT1234",
"registration_country": "CYP"
},
"cloud_name": "crmdotcom",
"organisation_tags": [
"Accounting"
],
"service_organisations": [
"1daf80b1-134b-36eb-7146-76dec04e6c5d"
],
"contact_registry": "true",
"locations": {
"id": "a6cc4f88-cab1-4ab2-98d3-4655789277e2",
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"care_of": "",
"lat": 35.157115,
"lon": 33.313719,
"google_place_id": "ChIJrTLr-GyuEmsRBfy61i59si0"
},
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
],
"partners": [
{
"id": "43f394c0-ece1-43a5-ab7d-b54ce9065fe7"
}
]
}
{id}
Removes an organisation
Path variables
The organisation (identifier) that will be removed
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
DELETE https://sandbox.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
{id}
/networkRetrieve all organisations
Path variables
Parent organisation (identifier) whose child organisations will be retrieved
Request parameters
Filter based on the organisation’s name
Filter based on the organisation’s relationship
(including service provider)
(including service point)
Filter based on the organisation’s group (only Venues can be grouped)
Filter based on the organisation’s industry
Filter based on the organisation’s industry sector
Tag filter for organisation
Filter based on the organisation’s business activity
Filter based on the organisation’s area
Filter based on the organisation’s country
Filter based on the organisation’s town/city
Defines whether and which child organisations total number should be returned
List of Enums for Image Type
Defines whether the organisation group should be returned as part of the response
Defines the free text search parameter based on the provided type (e.g. name)
Defines the entitiy type that the search will be applied
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Defines whether the total number that belong to such organisation should be retrieved (applicable for departments)
Defines whether the operation details of such organisations should be retrieved or not
Defines whether custom fields should be retrieved or not (via List/Get APIs)
Filters based on custom fields (key/value set should be semicolon separated)
Filter based on organisation status
Filter based on TAP code
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
Information about the business network of a business semantic parent organisation
The organisation identifier
The organisatio name
The organisation description
Information about the child organisations
Defines the relationship of the child organisation with the business semantic parent organisation
The total number of child organisations
Information about the organisation’s groups
The organisation group identifier
The organisation group name
Information about the organisation’s location
Information about the organisation’s location
The location identifier
The name of the location
The address of the location
Additional address information about the location
The state/province/county of the location
The town/city of the location
The postal code of the location
The country code of the location
The care of information of the location
The latitude of the location
The longitude of the location
The Google textual identifier that uniquely identifies a location
The creative identifier
Information about the creative type
Partner logos configurable by SO, applicable for Business, Merchant, Venue
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
The creative width
The creative height
The creative format
The creative content URL
The creative public identifier
Information about the creative transformations
The transformed creative width
The transformed creative height
The transformed creative URL
Information about the organisation’s industry
The industry identifier
The industry name
Information about the organisaion’s industry sectors
Information about the industry sectors
The industry sector identifier
The industry sector name
Information about the organisaion’s business activities
Information about the business activity
The business activity identifier
The business activity name
The total number of users for that organisation (applicable for departments)
The organisation operation details (retrieved only if operation_details = true)
Details about the organisation’s working hours
The day of the week that the organisation is open
The time that the organisation opens
The time that the organisation closes
The opening hours for each organisation’s operation type
Details about the organisation’s availability to offer its services
The organisation’s operation type
Defines whether the organisation is temporary closed for offering its services
Defines whether organisation supports contact registry
The custom field’s unique key
The custom field’s value
The status of the organisation
The date that such entity was created
The page number
The number of records per page
The overal number of records
GET /organisations/{id}/network HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "CRM.COM Cyprus",
"description": "Lorem Ipsum",
"child_organisations": [
{
"relationship": "MERCHANTS",
"count": 21
}
],
"locations": [
{
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"care_of": "",
"lat": "35.157115",
"lon": "33.313719",
"googleplaceid": "ChIJrTLr-GyuEmsRBfy61i59si0"
}
],
"creatives": [
{
"id": "CA123456789AQWSXZAQWS1236547896541",
"type": "PROFILEIMAGE",
"width": 2159,
"height": 3075,
"format": "jpg",
"url": "https://assets.crm.com/image/offer.jpg",
"public_id": "crm-com/image",
"media": [
{
"width": 200,
"height": 300,
"url": "https://asset.crm.com/image/offer/c_scale,w_200/offer.jpg"
}
]
}
],
"industry": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Restaurant"
},
"industry_sectors": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Bar"
}
],
"business_activities": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Bar & Grill"
}
]
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
GET https://sandbox.crm.com/backoffice/v1/organisations/d332dd8a-254e-47c9-ba1f-3f369877a9b3/network?relationship=VENUE HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"content": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "CRM.COM Cyprus",
"description": "Lorem Ipsum",
"groups": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Seasonal"
}
],
"locations": [
{
"id": "LOC123456234567345674567895678IK",
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"care_of": "",
"lat": 35.157115,
"lon": 33.313719,
"googleplaceid": "ChIJrTLr-GyuEmsRBfy61i59si0"
}
],
"creatives": [
{
"id": "CA123456789AQWSXZAQWS1236547896541",
"usage_type": "ATTACHMENT",
"width": 2159,
"height": 3075,
"format": "jpg",
"url": "https://assets.crm.com/image/logo.jpg",
"public_id": "crm-com/image",
"media": [
{
"width": 200,
"height": 300,
"url": "https://asset.crm.com/image/offer/c_scale,w_200/logo.jpg"
}
]
}
],
"industry": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Restaurant"
},
"industry_sectors": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Bar"
}
],
"business_activities": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Bar & Grill"
}
],
"users_count": 24,
"operation_details": {
"opening_hours": [
{
"day_of_week": "MONDAY",
"opens": "09:00",
"closes": "20:00",
"operation": "PICK_UP"
}
],
"short_term_operations": [
{
"operation": "DELIVERY",
"is_closed": "false"
}
]
},
"contact_registry": "true"
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
Get details of a single Organisation
Path variables
The organisation (identifier) that will be retrieved
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
The organisation identifier
The organisation name
The organisation description
The organisation type
Determines whether the organisation record will be used for test purposes
Determines whether the sandbox mode is enabled or not
Defines whether the organisation is the primary business of the business network
Information about the organisation’s groups
The organisation group identifier
The organisation group name
Information about the organisation’s contact details
Information about the owner (admin user) of the organisation
The contact detail identifier
The name of the contact information
The type of the contact information
The value of the specific contact information
The country code related to the contact detail of type phone
Information about the organisation’s locations
Information about the organisation’s location
The location identifier
The name of the location
The address of the location
Additional address information about the location
The state/province/county of the location
The town/city of the location
The postal code of the location
The country code of the location
The care of information of the location
The latitude of the location
The longitude of the location
The Google textual identifier that uniquely identifies a location
Information about the organisation’s transaction acquiring points (taps)
Information about the organisation’s external references
The transaction acquiring point identifier
The transaction acquiring point name
The transaction acquiring point code
Defines whether the transaction acquiring point is active or not
The transaction acquiring point description
IP address of External Device
Port of the External IP
The transaction acquiring point type
The transaction acquiring point that the event was submitted from (id or code must be specified). TAP and Organisation (id) attributes are semi-optional
The transaction acquiring point identifier
The transaction acquiring point code
Information about the organisation’s industry
The industry identifier
The industry name
Information about the organisation’s industry sectors
Information about the industry sectors
The industry sector identifier
The industry sector name
Information about the organisation’s business activities
Information about the business activity
The business activity identifier
The business activity name
Defines whether the new organisation will have the same industry, industry sectors and business activities as its parent organisation
Details about the organisation profile
The organisation’s registration number
The organisation’s TAX reference number
The organisation’s VAT reference number
The company’s registrationc country code
The parent organisation identifier that this organisation belongs to
The name that the organisation will have on the cloud (applicable for Service Owner organisations; special characters not allowed)
The tags of the organisation
The organisations (service owners) that the organisation (transaction processor) serves
Details about the organisation from where such event was posted
The organisation identifier
The organisation name
The creative identifier
Information about the creative type
Partner logos configurable by SO, applicable for Business, Merchant, Venue
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
Applicable only for Applications
The creative width
The creative height
The creative format
The creative content URL
The creative public identifier
Information about the creative transformations
The transformed creative width
The transformed creative height
The transformed creative URL
Defines whether the organisation supports contact registry
The custom field’s unique key
The custom field’s value
The status of the organisation
Defines the partners that are assigned to this organisation and their logos will be shown on the back-end SPA. Applicable only for organisations of type Business, where Service Owners will be responsible for assigning such information
The partner identifier
The partner name
The date that such entity was created
Details regardifn the billing business
The billing business identifier
The billing business name
The default service assigned to the organisation
The service identifier
The service name
The service SKU
GET https://sandbox.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD HTTP/1.1
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Delicious Bite",
"description": "Lorem Ipsum",
"org_type": "SERVICE_OWNER",
"test_mode": "false",
"is_sandbox_on": "false",
"is_business": "false",
"groups": [
{
"id": "OGD1E31269B76D7A65ACCE45B2E68DFD",
"name": "Seasonal"
}
],
"contact_info": [
{
"id": "CON123456234567345674567895678IK",
"name": "Main Office",
"type": "PHONE",
"value": "johndoe@deliciousfood.com",
"country_code": "CYP"
}
],
"locations": [
{
"id": "LOC123456234567345674567895678IK",
"name": "Head Office",
"address_line_1": "Elia Papakyriakou 21",
"address_line_2": "7 Tower Stars",
"state_province_county": "Egkomi",
"town_city": "Nicosia",
"postal_code": "2415",
"country_code": "CY",
"care_of": "c/o Company",
"lat": 35.157115,
"lon": 33.313719,
"google_place_id": "ChIJrTLr-GyuEmsRBfy61i59si0"
}
],
"taps": [
{
"id": "TAP123456234567345674567895678IK",
"name": "ePOS",
"code": "EP12",
"is_active": "true",
"description": "electronic POS",
"external_ip": "82.102.93.164",
"external_port": "9100",
"tap_type": "EXTERNAL_REF",
"external_type": {
"id": "4c01d5e4-02c9-ae89-4a3c-eaeb3174fcf0",
"code": "TAP001"
}
}
],
"industry": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DRT",
"name": "Restaurant"
},
"industry_sectors": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DWQ",
"name": "Bar"
}
],
"business_activities": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DBU",
"name": "Bar & Grill"
}
],
"inherit_from_parent": "false",
"organisation_profile": {
"registration_number": "1234",
"tax_reference_number": "TAX1234",
"vat_reference_number": "VAT1234",
"registration_country": "CYP"
},
"organisation_id": "7e8e39de-2f80-d2fe-b1f9-25b0cf4b2fbf",
"cloud_name": "crmdotcom",
"organisation_tags": [
"Accounting"
],
"service_organisations": [
{
"id": "ed165bb7-666e-d55c-7e3d-1127909d10a3",
"name": "CRMdotCOM"
}
],
"creatives": [
{
"id": "CA123456789AQWSXZAQWS1236547896541",
"usage_type": "ATTACHMENT",
"width": 2159,
"height": 3075,
"format": "jpg",
"url": "https://assets.crm.com/image/logo.jpg",
"public_id": "crm-com/image",
"media": [
{
"width": 200,
"height": 300,
"url": "https://asset.crm.com/image/offer/c_scale,w_200/logo.jpg"
}
]
}
],
"contact_registry": "true",
"custom_fields": [
{
"key": "back_office",
"value": "0001-12345"
}
],
"status": "SUSPEND",
"partners": [
{
"id": "43f394c0-ece1-43a5-ab7d-b54ce9065fe7",
"name": "Yellow Umbrella Corp."
}
]
}
{id}
/activity_feedGet the activity feed of a single organisation
Path variables
The organisation (identifier) whose activity will be retrieved
Request parameters
The activity type
The created date of the activity (no time)
Defines on which attribute the results should be sorted
Defines how the results will be ordered
The page number that should be retrieved
The size (total records) of each page
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
The request has succeeded
Body
Details about the activity feed
The activity (feed) identifier
The entity’s number
The entity’s reference number
The entity’s code
The entity’s life cycle state
The entity’s created date
The activity (feed) type
The activity (feed) direction
The activity (feed) notes
The entity’s type name
The entity’s total amount
The entity’s currency
The entity’s due date in case of Invoices
The entity that the topup was performed for
The top up identifier
The number or code of the topup entity
The type of the topup entity
The page number
The number of records per page
The overal number of records
GET https://stagingapi.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD/activity_feed HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
Content-Type: application/json
{
"activity_feed": [
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"number": "I10003",
"reference_number": "Ref12345678",
"code": "123456789ABE2364",
"state": "POSTED",
"created_date": 1576486645,
"activity_type": "INVOICE",
"direction": "OUTGOING",
"notes": "This Invoice is created for November 2019",
"type": "INVOICE",
"total_amount": 200,
"currency": "EUR",
"due_date": 1576486645,
"topup_entity": {
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD",
"number": "AC00123 John Johnson",
"type": "ACCOUNT"
}
}
],
"paging": {
"page": 2,
"size": 20,
"total": 5124
}
}
{id}
/switchSwitch the user to another organisation
Path variables
The organisation (identifier) that will be switched to
Notes
As part of “changing organisations that an user belongs to” flow, the user will have a different role as assigned to him when he was invited to the organisation that was switched to
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
POST /organisations/CAD1E31269B76D7A65ACCE45B2E68DFD/switch HTTP/1.1
authorization: 4AD9C84FA60F9FE407140E20F707726A
HTTP/1.1 200 OK
{id}
/masqueradeSwitch the user to another organisation
Path variables
The organisation (identifier) that will be masqueraded to
Notes
As part of “masquerade” flow, the masqueraded user will have the same role as the one from the initial organisation that such user signed in.
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Responses
OK
POST https://sandbox.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD/masquerade HTTP/1.1
authorization: eyJraWQiOiIvcHJpdmF0ZUtleS5wZW0iLCJ0eXAiOiJKV
HTTP/1.1 200 OK
{id}
/actionsPerform an action on a single organisation
Path variables
The organisation (identifier) that an action will be applied on it
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The action that will be applied on the organisation
Enable live mode on the organisation
The organisation name that will be used when copying an organisation (applicable when action == COPY)
Responses
OK
Body
The organisation identifier
POST https://sandbox.crm.com/backoffice/v1/organisations/CAD1E31269B76D7A65ACCE45B2E68DFD/actions HTTP/1.1
Content-Type: application/json
{
"action": "MODE"
}
HTTP/1.1 200 OK
Content-Type: application/json
{
"id": "CAD1E31269B76D7A65ACCE45B2E68DFD"
}
{id}
/media_groupsLink an organisation with one or many media groups
Path variables
The organisation (identifier) that media groups will be updated
Notes
Uploading media for an organisation requires the execution of the following APIs
- Create new Media Group
- Create Organisation Media Groups
- Upload Media
- Perform Cloudinary Upload (where CRM will send all signature details)
- Cloudinary service calls back CRM media group (using an internal callback)
Request headers
Authorization Token
The secret api key required for API calls to ensure that the client is trusted
Request body
The media group identifier