> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trackstarhq.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Search API Logs

> Returns the API requests your organization made to Trackstar, most recent first. Filter by connection, integration, date range, request path, method, or status.



## OpenAPI

````yaml get /api-logs
openapi: 3.1.0
info:
  description: >

    Trackstar is a Unified API that provides standard endpoints for Supply Chain
    Logistics. We currently offer an API for Warehouse Management Systems (WMS).
  title: Trackstar API
  version: 0.1.0
servers:
  - description: Trackstar API
    url: https://production.trackstarhq.com
security: []
tags: []
externalDocs:
  description: Trackstar API Documentation
  url: https://docs.trackstarhq.com
paths:
  /api-logs:
    get:
      tags:
        - Auth
      summary: Search API Logs
      description: >-
        Returns the API requests your organization made to Trackstar, most
        recent first. Filter by connection, integration, date range, request
        path, method, or status.
      operationId: get_search_api_logs
      parameters:
        - in: query
          name: start_date
          description: >-
            Only return requests received at or after this time. Cannot be more
            than 180 days ago, which is how long we retain logs.
          schema:
            type: string
            format: date-time
            example: '2024-01-15T00:00:00Z'
          required: true
        - in: query
          name: end_date
          description: >-
            Only return requests received at or before this time. Defaults to
            now.
          schema:
            type: string
            format: date-time
            example: '2024-01-16T00:00:00Z'
          required: false
        - in: query
          name: connection_id
          description: Only return requests made against this connection.
          schema:
            type: string
            example: abc123def456abc123def456abc123de
          required: false
        - in: query
          name: integration_name
          description: >-
            Only return requests made against connections to this integration.
            The same name can exist across types, so pair it with
            `integration_type` to disambiguate.
          schema:
            type: string
            enum:
              - active-ants
              - adp
              - amazon
              - amphora
              - amplifier
              - ams
              - amware
              - atomix
              - bdi
              - bergen
              - bigblue
              - bigcommerce
              - bleckmann
              - bluebox
              - byrd
              - camelot
              - canary7
              - capacity
              - carton-cloud
              - cin7-omni
              - cirro
              - clarus
              - controlport
              - crafty
              - cwr
              - cybership
              - dart
              - darwynn-fulfillment
              - davinci
              - dcl
              - dear-systems
              - deposco
              - dhl-ecom
              - dhl-express
              - distribution-alternatives
              - distribution-management
              - dotcom-distribution
              - douyin
              - dpd
              - ebay
              - elite-ops
              - eshipping
              - etsy
              - evolve
              - excelsior
              - extensiv-3pl-central
              - fabfitfun
              - faire
              - fba
              - fedex
              - fedex-fulfillment
              - ffe
              - finale
              - flat-fee-shipping
              - flexport
              - florisoft
              - flowspace
              - forceget
              - fulfil
              - fulfillment
              - fulfillment-lab
              - fulfillor
              - fulfilmentcrowd
              - fullgood-fulfillment
              - g-global
              - gobolt
              - greenmark
              - groupon
              - helm-wms
              - hive
              - i-fulfilment
              - icreate
              - ilg
              - infoplus
              - itshere
              - jas
              - jaygroup
              - jazz-central
              - landmark
              - leanafy
              - leanware
              - lineage
              - linnall
              - linnworks
              - logicpod
              - logiwa
              - logiwa-io
              - longtail
              - luxroutage
              - mabang
              - magento
              - mai
              - mainfreight
              - masonhub
              - mayple
              - mintsoft
              - mirakl
              - mochila-fulfillment
              - monta
              - netsuite
              - next3pl
              - nfi
              - nimble
              - nlrp
              - nri
              - nuorder
              - oia-global
              - omnitrans
              - ongoing
              - orderflow
              - orderwise
              - osa-commerce
              - overstock
              - packem
              - packiyo
              - pattern
              - peoplevox
              - picqer
              - pimento
              - podfoods
              - portless
              - postnord
              - pulpo
              - qls
              - quiet
              - rjw
              - royal-mail
              - rush-order
              - salesupply
              - sandbox
              - shipbob
              - shipedge
              - shipfusion
              - shiphero
              - shipmonk
              - shipnetwork
              - shipoffers
              - shipout
              - shipping-and-handling
              - shipping-tree
              - shippingbo
              - shipstation
              - shipstream
              - shipwire
              - shopify
              - skladon
              - skulabs
              - skusavvy
              - skuvault
              - smart-warehousing
              - smartpack
              - sojo
              - souko
              - squarespace
              - star
              - states-logistics
              - stock-and-trace
              - stockhub
              - stord
              - teamship
              - teapplix
              - techship
              - tiktok
              - tradepeg
              - unis
              - unleashed
              - ups
              - usps
              - veeqo
              - veracore
              - vertical-cold
              - vox
              - walmart
              - warehance
              - warehouseos
              - wayfair
              - whiplash
              - wineshipping
              - wix
              - woocommerce
              - xb-fulfillment
              - xorosoft
              - zenventory
              - zoho
            example: example_wms
          required: false
        - in: query
          name: integration_type
          description: >-
            Only return requests made against connections of this integration
            type.
          schema:
            type: string
            enum:
              - wms
              - freight
              - cart
              - carrier
              - erp
            example: wms
          required: false
        - in: query
          name: request_method
          description: Only return requests made with this HTTP method.
          schema:
            type: string
            enum:
              - GET
              - POST
              - PUT
              - DELETE
              - PATCH
              - HEAD
              - OPTIONS
            example: GET
          required: false
        - in: query
          name: request_path
          description: >-
            Only return requests made to this endpoint. Path parameters are
            replaced with `<path_param>`, so a request to `/wms/orders/123` is
            stored as `/wms/orders/<path_param>`.
          schema:
            type: string
            example: /wms/orders
          required: false
        - in: query
          name: status_code
          description: Only return requests that returned this HTTP status code.
          schema:
            type: integer
            example: 200
          required: false
        - in: query
          name: limit
          description: >-
            The maximum number of requests to return per page. The default is
            100. Minimum 1 and maximum 5000. Fewer may be returned if the page
            would be too large, in which case a `next_token` is included.
          schema:
            type: integer
            default: 100
            minimum: 1
            maximum: 5000
            example: 100
          required: false
        - in: query
          name: page_token
          description: >-
            The page token to use to retrieve the next page of results. If this
            field is omitted, there are no subsequent pages.
          schema:
            type: string
            example: page_token
          required: false
        - in: header
          name: x-trackstar-api-key
          description: Your organization-level Trackstar API key.
          schema:
            type: string
            example: <x-trackstar-api-key>
          required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APILogsResponseSchema'
          description: Successful response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationError'
          description: Validation error
components:
  schemas:
    APILogsResponseSchema:
      type: object
      properties:
        data:
          type: array
          description: The requests that matched the search, most recent first.
          items:
            $ref: '#/components/schemas/APILog'
        total_count:
          type: integer
          description: The number of items returned.
          example: 1
        next_token:
          type:
            - string
            - 'null'
          description: >-
            See [pagination](/how-to-guides/about-the-api#pagination) for more
            details.
          example: next_token
      required:
        - data
        - next_token
        - total_count
      additionalProperties: false
      title: APILogsResponseSchema
    ValidationError:
      properties:
        error:
          type: string
        detail:
          type: object
          properties:
            <location>:
              type: object
              properties:
                <field_name>:
                  type: array
                  items:
                    type: string
      required:
        - error
      type: object
      title: ValidationError
    APILog:
      type: object
      properties:
        request_id:
          type:
            - string
            - 'null'
          description: >-
            The id of the request, also returned on every response in the
            `X-Request-Id` header.
          example: Root=1-abc12345-abc123def456abc123def456
        connection_id:
          type:
            - string
            - 'null'
          description: The connection the request was made against.
          example: abc123def456abc123def456abc123de
        integration_name:
          type:
            - string
            - 'null'
          description: The integration the connection belongs to.
          example: example_wms
        integration_type:
          type:
            - string
            - 'null'
          description: The type of integration the connection belongs to.
          example: wms
        request_time:
          type: string
          format: date-time
          description: When Trackstar received the request.
          example: '2024-01-15T13:45:30Z'
        request_method:
          type: string
          description: The HTTP method of the request.
          example: GET
        request_path:
          type: string
          description: >-
            The endpoint that was called, with path parameters replaced by
            `<path_param>`.
          example: /wms/orders/<path_param>
        path_param:
          type:
            - string
            - 'null'
          description: The path parameter the request was made with.
          example: '123'
        query_params:
          description: The query parameters the request was made with.
          type:
            - object
            - 'null'
          example:
            limit: 100
        request_body:
          description: The body the request was made with.
          type:
            - object
            - 'null'
          example:
            reference_id: order-1001
        integration_request_bodies:
          type:
            - array
            - 'null'
          description: >-
            The calls Trackstar made to the integration while handling this
            request. Credentials are redacted.
          items:
            $ref: '#/components/schemas/APILogIntegrationRequest'
        status_code:
          type: integer
          description: The HTTP status code the request returned.
          example: 200
        error:
          type:
            - string
            - 'null'
          description: The error the request returned, if it failed.
          example: Order not found
        error_origin:
          type:
            - string
            - 'null'
          description: Whether the error came from Trackstar or the integration.
          example: integration
        duration_ms:
          type:
            - integer
            - 'null'
          description: How long the request took, in milliseconds.
          example: 142
      required:
        - connection_id
        - duration_ms
        - error
        - error_origin
        - integration_name
        - integration_request_bodies
        - integration_type
        - path_param
        - query_params
        - request_body
        - request_id
        - request_method
        - request_path
        - request_time
        - status_code
      additionalProperties: false
      title: APILog
    APILogIntegrationRequest:
      type: object
      properties:
        url:
          type:
            - string
            - 'null'
          description: The integration endpoint Trackstar called.
          example: https://api.example-wms.com/orders
        method:
          type: string
          description: The HTTP method Trackstar used.
          example: POST
        body:
          description: The body Trackstar sent to the integration.
          type:
            - object
            - 'null'
          example:
            order_number: '1001'
      required:
        - body
        - method
        - url
      additionalProperties: false
      title: APILogIntegrationRequest

````