Gladly Events API

An **Event** is something that has happened in Gladly. The Events API allows you to extract event details from the past 24 hours.

Operations 1

GET /api/v1/events List Events #

Documentation

Specifications

Schemas & Data

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/gladly-events-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

gladly-events-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Gladly Events API
  version: '1.0'
  description: '# Introducing the Gladly API


    At Gladly, we believe that customer service is best when it''s a conversation.'
servers:
- url: https://{organization}.gladly.com/api/v1
  description: Production
  variables:
    organization:
      default: organization
      description: Your Gladly organization subdomain
- url: https://{organization}.gladly.qa/api/v1
  description: Sandbox
  variables:
    organization:
      default: organization
      description: Your Gladly QA organization subdomain
security:
- basicAuth: []
tags:
- name: Events
  description: An **Event** is something that has happened in Gladly. The Events API allows you to extract event details from the past 24 hours.
paths:
  /api/v1/events:
    parameters:
    - name: startAt
      required: true
      in: query
      description: 'Starting time of the events interval. This is based on the `timestamp` field which indicates when the event was recorded. Must be from last 24 hours.


        The date should be in ISO 8601 format.

        '
      schema:
        type: string
        example: '2020-04-13T19:27:34-09:00'
    - name: endAt
      in: query
      description: 'Ending time of the events interval. This is based on the `timestamp` field which indicates when the event was recorded. If unspecified, current time will be implied.


        The date should be in ISO 8601 format.

        '
      required: false
      schema:
        type: string
        example: '2020-04-13T20:27:12-09:00'
    - name: entities
      required: true
      in: query
      description: 'Entity types that have associated events. Any number of types is acceptable and at least one must be present


        Available Types: `AGENT_AVAILABILITY`, `AGENT_STATUS`, `CONTACT`, `CONVERSATION`, `CUSTOMER`, `CUSTOMER_PROFILE`, `PAYMENT_REQUEST`,`TASK`

        '
      schema:
        type: array
        example:
        - AGENT_AVAILABILITY
        - AGENT_STATUS
    get:
      tags:
      - Events
      summary: List Events
      description: 'Returns a stream of events for the specified entities within the given time range. Responses are streamed using JSONL.


        Events are up to 15 seconds behind real-time.


        ```

        /api/v1/events?startAt=2020-05-20T14:00:00Z&entities=AGENT_STATUS&entities=AGENT_AVAILABILITY

        ```'
      responses:
        '200':
          description: Events Streaming Response
          content:
            application/x-jsonlines:
              schema:
                title: Event Response Schemas
                oneOf:
                - title: Agent Availability Focus Entered
                  type: object
                  required:
                  - id
                  - type
                  - timestamp
                  - initiator
                  - content
                  properties:
                    id:
                      type: string
                      description: Unique event ID
                      example: zGaHXjD4SR-moMR9LbULDa
                    type:
                      type: string
                      example: AGENT_AVAILABILITY/FOCUS_ENTERED
                      enum:
                      - AGENT_AVAILABILITY/FOCUS_ENTERED
                    timestamp:
                      type: string
                      format: ISO 8601
                      description: Time the event was recorded
                      example: '2019-07-03T04:30:12.07Z'
                    initiator:
                      $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/0/properties/initiator'
                    content:
                      title: Content
                      description: Content for event
                      required:
                      - agentId
                      - context
                      properties:
                        agentId:
                          type: string
                          description: ID of the agent who entered or exited focus.
                          example: zGaHXjD4SR-moMR9LbULDa
                        context:
                          description: The state of the agent immediately before the event occurred.
                          required:
                          - availableFor
                          properties:
                            availableFor:
                              type: array
                              enum:
                              - MAIL
                              - MESSAGING
                              - TASK
                              - VOICE
                              description: 'The set of channel types for which the agent is available for.

                                '
                              example:
                              - MAIL
                              - TASK
                              - VOICE
                - title: Agent Availability Focus Exited
                  type: object
                  required:
                  - id
                  - type
                  - timestamp
                  - initiator
                  - content
                  properties:
                    id:
                      type: string
                      description: Unique event ID
                      example: zGaHXjD4SR-moMR9LbULDa
                    type:
                      type: string
                      example: AGENT_AVAILABILITY/FOCUS_EXITED
                      enum:
                      - AGENT_AVAILABILITY/FOCUS_EXITED
                    timestamp:
                      type: string
                      format: ISO 8601
                      description: Time the event was recorded
                      example: '2019-07-03T04:30:12.07Z'
                    initiator:
                      $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/0/properties/initiator'
                    content:
                      $ref: '#/paths/~1api~1v1~1events/get/responses/200/content/application~1x-jsonlines/schema/oneOf/0/properties/content'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/0'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/1'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/2'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/3'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/4'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/5'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/6'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/7'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/8'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/9'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/10'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/11'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/12'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/13'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/14'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/15'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/16'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/17'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/18'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/19'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/20'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/21'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/22'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/23'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/24'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/26'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/27'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/28'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/29'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/30'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/32'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/36'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/37'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/38'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/39'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/40'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/41'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/42'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/43'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/44'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/45'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/46'
                - $ref: '#/paths/~1gladly~1webhook/post/requestBody/content/application~1json/schema/oneOf/47'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Errors'
              examples:
                invalid parameter:
                  value:
                    errors:
                    - attr: startAt
                      code: invalid
                      detail: endAt must occur after startAt
      operationId: getApiV1Events
      x-operation-id-source: derived
components:
  schemas:
    Errors:
      type: object
      properties:
        errors:
          type: array
          items:
            $ref: '#/components/schemas/Error'
          example:
          - attr: content
            code: blank
            detail: content cannot be blank
    Error:
      type: object
      properties:
        attr:
          type: string
          description: Identifies the field causing the error
        code:
          type: string
          description: Code indicating the error type
        detail:
          type: string
          description: More details describing what went wrong
  securitySchemes:
    BasicAuth:
      type: http
      scheme: basic
      description: 'Gladly API uses token-based **Basic Authentication**. API tokens are associated with designated Gladly users.

        To create and use an API token, your user must have the API User permission. An API token can be used to perform any API request without restriction.


        | user name   | password  |

        | ----------- | --------- |

        | agent email | API token |


        The credentials must be passed via an `Authorization` HTTP header. All requests must be made over HTTPS.


        ```shell

        curl -u user@organization.com:$GLADLY_API_TOKEN \

        https://organization.gladly.com/api/v1/organization

        ```

        '
    basicAuth:
      type: http
      scheme: basic
      description: HTTP Basic auth — username is the API user email; password is the API token. Requires the "API User" permission.
x-tagGroups:
- name: REST API
  tags:
  - Agents
  - Public Answer
  - Answer Management
  - Audiences
  - Business Hours
  - Communications
  - Conversations
  - Customers
  - Events
  - Export
  - Freeform Topics
  - Inboxes
  - Organization
  - Proactive Conversations
  - Reports
  - Tasks
  - Teams
  - User Identity
  - Topics
  - Webhooks
- name: Webhooks
  tags:
  - Summary
  - Payloads
- name: Lookup API
  tags:
  - Customer Lookup
- name: Resources
  tags:
  - Versioning
  - Error Handling
  - Rate Limit
  - Rich Content
  - Launching Soon