Skip to main content
Skip table of contents

REST API - Authentication & Error Handling

This article will give you an overview for the following topics.

  1. Rate Limiting

  2. Authentication Types

  3. Error Handling

Rate Limiting

There is currently no rate limiting on any instance of EventLyte CRM.

Authentication Types

The REST API only supports authentication using Personal Access Tokens (PATs).

HTTP Token Authentication

This authentication method involves sending a Personal Access Token using basic authentication.

The Authorization header must start with “Basic “ with USER:PAT being base64 encoded.

BASH
curl --location 'https://your-instance.crm.eventlyte.com/api/records/contacts' \
  --header 'Content-Type: application/json' \
  --header 'Authorization: Basic {base64 USER:PAT}' \
  --data '{}'

Generating Tokens

To generate a personal access token:

  1. Log into EventLyte CRM

  2. Go to Settings in the top right

  3. Select “Access Tokens”

  4. Add a new token:

    1. Enter a friendly name

    2. Define token lifetime (up to 90 days)

    3. Click Save

  5. Copy the generated token and use it in REST API requests using Basic Authentication.

This token can be revoked within EventLyte CRM at any time if you require to, such as the token being compromised.

Error Handling

The API will do its best to reduce errors being returned to API consumers. This increases the availability of the record for use onsite and within the CRM.

When extra fields are sent to the API for saving, and the field does not exist, the field is placed in a holding area and not discarded. A section within the CRM then will enable you to review missing fields and be recommended to add fields in order to view the data.

Error Response Format

EventLyte uses an RFC 7807 compliant error response when returning errors, meaning that all errors can be handled with the same response body.

CODE
{
  "type": "https://example.com/api/records/contacts",
  "title": "Error",
  "status": 400,
  "detail": "Error details available here",
  "instance": "/api/records/contacts"
}

For further information, refer to: https://www.rfc-editor.org/rfc/rfc7807

Expected Response Codes

Code

Expected Response Type

Description

200

Record

The data has been saved successfully

400

RFC 7807

The data within the request body is invalid or the data being sent in a field does not match

404

RFC 7807

The URL path does not exist within the API

500

RFC 7807

An error has occurred with a message in the response body indicating the type of error

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.