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

# Export your team's audit log as CSV

> Exports the events audit.list lists, with the same kind, from and to, as a CSV file.

> [accordion] Details
>
> * Owners and Admins only. An API key needs team:manage.
>
> * content holds the CSV text, newest event first: time\_utc, actor (the member, and the API key or app they used), action, kind, target and details (the value before and after, fields changed or viewed, never their values, and a transfer's size, address and user agent). Save it as file\_name.
>
> * One file holds up to 2000 events. When more remain, next\_cursor is set: pass it as cursor, with the same filters, for the next file, whose header row repeats.
>
> * To answer a question about the events, audit.list returns them as JSON.
>
> * Events stay listed for 90 days.
>
> * **Callers:** an API key, an MCP OAuth token or a Dashboard session.
>
> * **Permission:** `team:manage`; an API key also needs `team:manage`.
>
> * **Effect:** Changes nothing.
>
> * **Errors:** [`business_account_required`](https://docs.pomerado.ai/errors#business_account_required), [`role_permission_missing`](https://docs.pomerado.ai/errors#role_permission_missing), and the [errors any request can get](https://docs.pomerado.ai/errors.md).


## OpenAPI

````yaml /api-reference/openapi.json get /v1/audit-events/export
openapi: 3.1.0
info:
  title: Pomerado API
  version: '1'
  description: >-
    Run and build website tools, follow their jobs, and manage logins, API keys
    and webhooks. Authenticate with a Pomerado API key (pom_…), an MCP OAuth
    token or a Dashboard session as a Bearer token.
servers:
  - url: https://api.pomerado.ai
security: []
tags:
  - name: account
    x-group: Account
  - name: api_keys
    x-group: API keys
  - name: environments
    x-group: Environments
  - name: connected_apps
    x-group: Connected apps
  - name: usage
    x-group: Usage
  - name: quota
    x-group: Quota
  - name: spend_controls
    x-group: Spend controls
  - name: usage_alerts
    x-group: Usage alerts
  - name: usage_summary
    x-group: Usage summary
  - name: billing
    x-group: Billing
  - name: integrations
    x-group: Integrations
  - name: connect
    x-group: Connect
  - name: code
    x-group: Code
  - name: logins
    x-group: Saved logins
  - name: two_factor
    x-group: 2FA
  - name: login_access
    x-group: Login access
  - name: tools
    x-group: Tools
  - name: shapes
    x-group: Shapes
  - name: webhooks
    x-group: Webhooks
  - name: payer_profiles
    x-group: Payer profiles
  - name: payer_addresses
    x-group: Payer addresses
  - name: payment_methods
    x-group: Payment methods
  - name: runs
    x-group: Runs
  - name: builds
    x-group: Builds
  - name: jobs
    x-group: Jobs
  - name: suggestions
    x-group: Suggestions
  - name: audit
    x-group: Audit
  - name: files
    x-group: Files
  - name: team
    x-group: Team
  - name: sso
    x-group: Single sign-on
  - name: issue_reports
    x-group: Problem reports
paths:
  /v1/audit-events/export:
    get:
      tags:
        - audit
      summary: Export your team's audit log as CSV
      description: >-
        Exports the events audit.list lists, with the same kind, from and to, as
        a CSV file.
      operationId: audit.export
      parameters:
        - name: kind
          in: query
          required: false
          description: >-
            Only events of these kinds: one, such as team.role_changed, or
            several comma-separated, such as team.role_changed,api_key.created.
            The kinds: team.member_added, team.role_changed,
            team.member_removed, team.invitation_sent, team.invitation_resent,
            team.invitation_revoked, login.access_granted, login.access_changed,
            login.access_revoked, api_key.created, api_key.revoked,
            tool.published, tool.deleted, tool.code_link_created,
            tool.code_downloaded, file.uploaded, login.created, login.updated,
            login.deleted, login.unlock_requested, login.unlock_granted,
            login.unlocked_replace_started, login.unlocked_delete_started,
            login.unlocked_change, login.revealed, login.sms_number_linked,
            login.sms_number_unlinked, webhook.created, webhook.updated,
            webhook.secret_rotated, webhook.tested, webhook.deleted,
            account.session_recordings_changed, account.two_step_rule_changed,
            account.identity_provider_only_changed, usage.daily_cap_changed,
            usage.overage_budget_changed, usage.alert_created,
            usage.alert_changed, usage.alert_deleted, usage.summary_changed,
            usage.dollar_alerts_changed, two_step.authenticator_added,
            two_step.authenticator_removed, two_step.passkey_added,
            two_step.passkey_renamed, two_step.passkey_removed,
            two_step.backup_codes_created, two_step.backup_code_used
          schema:
            type: string
        - name: from
          in: query
          required: false
          description: 'At or after, inclusive (default and earliest: 90 days ago)'
          schema:
            type: string
        - name: to
          in: query
          required: false
          description: 'Before (default: now)'
          schema:
            type: string
        - name: cursor
          in: query
          required: false
          description: The next_cursor of the previous page
          schema:
            type: string
        - name: limit
          in: query
          required: false
          description: Events in this file, 1 to 2000 (default 2000)
          schema:
            type: string
      responses:
        '200':
          description: The events as CSV
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuditExport'
        '400':
          description: invalid_request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: unauthorized, reauthentication_required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: >-
            business_account_required, role_permission_missing, forbidden,
            environment_not_allowed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: server_busy
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: internal_error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '503':
          description: temporarily_unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearer: []
components:
  schemas:
    AuditExport:
      type: object
      required:
        - file_name
        - media_type
        - content
        - rows
        - next_cursor
      properties:
        file_name:
          type: string
          description: >-
            A name to save it under, such as
            pomerado-audit-log-2026-09-01-to-2026-11-30.csv
        media_type:
          type: string
          enum:
            - text/csv
        content:
          type: string
          description: >-
            The CSV text: a header row (time_utc, actor, action, kind, target,
            details), then one row per event, newest first, each line ending in
            CRLF. A field a spreadsheet would read as a formula starts with an
            apostrophe
        rows:
          type: number
          description: How many events it holds
        next_cursor:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Set when older events in the range didn't fit: pass it as cursor,
            with the same kind, from and to, for the next file. Null when this
            one ends the range
      additionalProperties: false
    Error:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - code
            - message
            - retryable
            - docs_url
          properties:
            code:
              type: string
            message:
              type: string
            retryable:
              type: boolean
            docs_url:
              type: string
            details:
              type: object
              required: []
              properties: {}
              additionalProperties:
                $id: /schemas/unknown
          additionalProperties: false
      additionalProperties: false
  securitySchemes:
    bearer:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.