> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.tabs.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.tabs.com/_mcp/server.

# Get all events

GET https://usage-events.prod.api.tabsplatform.com/v1/events

Fetches all usage events, and can be filtered as needed. Reach out to your account manager if you would like to participate in the Beta for the new Usage API.

Reference: https://docs.tabs.com/api-reference/events/get-events

## OpenAPI Specification

```yaml
openapi: 3.1.0
info:
  title: Tabs External API
  version: 1.0.0
paths:
  /v1/events:
    get:
      operationId: get-events
      summary: Get all events
      description: >-
        Fetches all usage events, and can be filtered as needed. Reach out to
        your account manager if you would like to participate in the Beta for
        the new Usage API.
      tags:
        - events
      parameters:
        - name: startDate
          in: query
          description: 'Start date for filtering events (UTC) (format: YYYY-MM-DDTHH:mm:ss)'
          required: false
          schema:
            type: string
        - name: endDate
          in: query
          description: 'End date for filtering events (UTC) (format: YYYY-MM-DDTHH:mm:ss)'
          required: false
          schema:
            type: string
        - name: ingestStartDate
          in: query
          description: >-
            Start ingest timestamp for filtering events (UTC) (format:
            YYYY-MM-DDTHH:mm:ss)
          required: false
          schema:
            type: string
        - name: ingestEndDate
          in: query
          description: >-
            End ingest timestamp for filtering events (UTC) (format:
            YYYY-MM-DDTHH:mm:ss)
          required: false
          schema:
            type: string
        - name: customerId
          in: query
          description: Tabs Customer ID to filter events
          required: false
          schema:
            type: string
        - name: eventTypeId
          in: query
          description: Event type ID to filter events
          required: false
          schema:
            type: string
        - name: source
          in: query
          description: Source to filter events
          required: false
          schema:
            type: string
        - name: limit
          in: query
          description: 'Number of events to return (default: 50, max: 1000)'
          required: false
          schema:
            type: integer
        - name: cursor
          in: query
          description: Cursor for pagination
          required: false
          schema:
            type: string
        - name: orderDirection
          in: query
          description: Sort direction (asc/desc)
          required: false
          schema:
            type: string
        - name: skipDeletionEvents
          in: query
          description: 'Include deleted events in the response (default: true)'
          required: false
          schema:
            type: boolean
            default: true
        - name: Authorization
          in: header
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Events retrieved successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EventsQueryResponse'
        '400':
          description: Bad request - Invalid parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
        '429':
          description: Too Many Requests - Rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RateLimitResponse'
        '500':
          description: Internal server error - Failed to retrieve events
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationErrorResponse'
servers:
  - url: https://usage-events.prod.api.tabsplatform.com
    description: https://integrators.prod.api.tabsplatform.com
components:
  schemas:
    EventDtoMetadata:
      type: object
      properties: {}
      title: EventDtoMetadata
    EventDto:
      type: object
      properties:
        manufacturerId:
          type: string
        eventTypeId:
          type: string
        metadata:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/EventDtoMetadata'
        value:
          type: string
        differentiator:
          type: string
        invoiceGroup:
          type: string
        idempotencyKey:
          type: string
        datetime:
          type: string
        customerId:
          type: string
        parentEventId:
          type: string
        source:
          type: string
        deleted:
          type: boolean
          description: Whether the event is deleted
      description: Event data transfer object
      title: EventDto
    EventsQueryResponse:
      type: object
      properties:
        events:
          type: array
          items:
            $ref: '#/components/schemas/EventDto'
          description: List of events
        count:
          type: integer
          description: Total count of events
        nextCursor:
          type: string
          description: Cursor for the next page of results
        hasMore:
          type: boolean
          description: Whether there are more results available
      description: Response containing a list of events with pagination information
      title: EventsQueryResponse
    ErrorDetail:
      type: object
      properties:
        code:
          type: integer
          description: Error code
        message:
          type: string
          description: Error message
        details:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: Map of field names to array of error messages
      description: Detailed error information
      title: ErrorDetail
    ValidationErrorResponse:
      type: object
      properties:
        success:
          type: boolean
          description: Indicates if the operation was successful
        message:
          type: string
          description: Human-readable error message
        error:
          $ref: '#/components/schemas/ErrorDetail'
      description: Error response for validation failures
      title: ValidationErrorResponse
    RateLimitResponse:
      type: object
      properties:
        statusCode:
          type: integer
          description: HTTP status code
        message:
          type: string
          description: Error message
        timestamp:
          type: string
          description: Timestamp when the error occurred
        path:
          type: string
          description: Request path
        method:
          type: string
          description: HTTP method
        retryAfter:
          type: integer
          description: Number of seconds to wait before retrying
      description: Rate limit exceeded error response
      title: RateLimitResponse
  securitySchemes:
    custom-header:
      type: apiKey
      in: header
      name: Authorization

```

## Examples



**Response**

```json
{
  "events": [
    {
      "eventTypeId": "550e8400-e29b-41d4-a716-446655440000",
      "value": "1",
      "differentiator": "mobile",
      "idempotencyKey": "018c1234-5678-7abc-def0-123456789abc",
      "datetime": "2024-01-15T10:30:00Z",
      "customerId": "550e8400-e29b-41d4-a716-446655440000",
      "deleted": false,
      "invoiceSplitKey": "invoice-123"
    }
  ],
  "count": 100,
  "nextCursor": "next-page-cursor",
  "hasMore": true
}
```

**SDK Code**

```python Success Response
import requests

url = "https://usage-events.prod.api.tabsplatform.com/v1/events"

headers = {"Authorization": "<apiKey>"}

response = requests.get(url, headers=headers)

print(response.json())
```

```javascript Success Response
const url = 'https://usage-events.prod.api.tabsplatform.com/v1/events';
const options = {method: 'GET', headers: {Authorization: '<apiKey>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go Success Response
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://usage-events.prod.api.tabsplatform.com/v1/events"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Authorization", "<apiKey>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby Success Response
require 'uri'
require 'net/http'

url = URI("https://usage-events.prod.api.tabsplatform.com/v1/events")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = '<apiKey>'

response = http.request(request)
puts response.read_body
```

```java Success Response
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://usage-events.prod.api.tabsplatform.com/v1/events")
  .header("Authorization", "<apiKey>")
  .asString();
```

```php Success Response
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://usage-events.prod.api.tabsplatform.com/v1/events', [
  'headers' => [
    'Authorization' => '<apiKey>',
  ],
]);

echo $response->getBody();
```

```csharp Success Response
using RestSharp;

var client = new RestClient("https://usage-events.prod.api.tabsplatform.com/v1/events");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "<apiKey>");
IRestResponse response = client.Execute(request);
```

```swift Success Response
import Foundation

let headers = ["Authorization": "<apiKey>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://usage-events.prod.api.tabsplatform.com/v1/events")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```