Need some help  with accessiBe?
Find your answers  here!

How can I add and manage subscriptions using API or CSV files?

If you want to automate subscription management, you can use our API to do that remotely or CSV file upload for your account page.

Please note:

  • In order to receive access to batch uploads or our API, contact sales first.
  • In both methods, you can upload up to 250 rows per request.

In this article, we’ll cover:

  • Uploading a batch CSV file.
  • Performing an API request.
  • Required/optional fields for the CSV file or API request.

How to upload a CSV file from your account

Make sure the first row has the below-required columns. Each row below the first is a single subscription, with fields corresponding to the columns. Jump to the next section to learn what fields the CSV needs to include and how they should be formatted.

Click here to download an example CSV file

1. Log into your accessiBe account by clicking ‘Account’ in the top right corner of accessiBe’s homepage.

Screenshot of instruction

2. Go to the ‘My Websites’ page.

Screenshot of instruction

3. Click the ‘Batch Management’ button

Screenshot of instruction

4. Choose the ‘CSV Import/Export’ option

Screenshot of instruction

5. Choose your file and click ‘Upload’

Screenshot of instruction

Error handling: if one or more of your entries failed, you'd see an explanation of the error fields right away. Usually, it’s because your entries did not pass our validations. For example, your email or telephone fields were not properly formatted. Simply fix the CSV and upload it again.

How to perform an API request

Click here to download an example JSON payload

  1. API Endpoint: https://accounts.accessibe.com/api/batch
  2. Add the API Key you received from us (contact us for one) as a HEADER of the request as follows: “Api-Key:{your-api-key}”.
  3. Make sure the “Content-Type” header is set to “application/json”.
  4. Make sure to POST the payload of your request in JSON format.
  5. Your JSON should include an ARRAY of objects. Each object contains the required/optional fields for managing a subscription.
  6. accessiBe will return an object with the results of the call, that includes the following fields:
    1. Status – true/false – the result of your call
    2. Message – a string explaining what went wrong if at all
    3. Options – an array including additional information such as failed validations
  7. Common errors:
    1. Missing or Incorrect API Key – either you did not include an “Api-Key” header with your API key, or your API key isn’t valid.
    2. Invalid JSON Payload – either the “Content-Type header” is not set to “application/json” or your payload is not a valid JSON format.
    3. Unknown error, contact us for help
    4. The batch operation failed, please check your data – this means that all of your entries failed, probably due to an entry not passing validation. Check the “validations” object inside the options array, it explains the issues.
      X of your entries failed; the rest succeeded! – this means that some of your entries did not pass validations, but others did. Check the “validations” object inside the options array, it explains the issues.

Required/optional fields for the CSV or API request

Excel file example screenshot

  • domain – The domain name you’d like to add. Note: uploading a row with a domain that already exists with edit the fields. This way you can modify subscription info. Make sure your domain is formatted as follows: “domain.com / sub.domain.com” (no HTTP/S protocol nor www).
  • newDomain – to edit a domain license, add the new domain name in this field, and the domain to edit in the “domain” field above. Note that you need special permission from us (not all accounts are allowed) and a special “transferKey” from us. Make sure to follow the same format as above.
  • planId – requires a number from 1 to 3 according to your desired plan:1 = Standard Plan | 5 = LargePlan | 2 = Huge Plan | 3 = Jumbo Plan.
  • contactName – the full name of the owner of the website (compliance requirement for the accessibility statement). Make sure to include a full name: e.g. “John Doe”.
  • contactPhone – the phone of the owner of the website without country code (compliance requirement for the accessibility statement). Make sure to include 9-10 digits only, without special characters, spaces or hyphens.
  • contactCountry – the country code of the website owner’s phone number. For example, “+1” for U.S and Canada (compliance requirement for the accessibility statement).
  • contactEmail – the email of the owner of the website (compliance requirement for the accessibility statement).
  • discountEnabled – can be empty | if you are entitled to a discount and you DON’T want it to be populated for that subscription (if you prefer it as a commission for example) put 0 in that field.
  • transferKey – can be empty | a key that allows editing domain licenses. This requires a special partnership deal with us, disregard it otherwise.
  • activationKey – can be empty | a key that allows subscriptions to be activated automatically without payment. This is for payments being done offline (wire-transfer, etc.), disregard it otherwise.
  • disableKey - can by empty |a key that allows subscriptions to be deactivated automatically. 
AUDIT YOUR WEBSITE FOR FREE

Find out now if your website is ADA  & WCAG  Compliant