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

# Batch Records

> Create up to 500 records, or upsert them with `match_attribute`. Each record succeeds or fails on its
own; the response reports every row.



## OpenAPI

````yaml /openapi-v1.json post /api/v1/crm/objects/{type_key}/records/batch
openapi: 3.1.0
info:
  title: AGO Public API
  version: 1.0.0
  description: Programmatic access to your AGO workspace.
servers:
  - url: https://{tenant_id}.api.useago.com
    description: AGO Public API v1
    variables:
      tenant_id:
        default: your-tenant-id
        description: Your AGO tenant identifier
security: []
paths:
  /api/v1/crm/objects/{type_key}/records/batch:
    post:
      tags:
        - CRM objects
      summary: Batch Records
      description: >-
        Create up to 500 records, or upsert them with `match_attribute`. Each
        record succeeds or fails on its

        own; the response reports every row.
      operationId: batch_crm_records
      parameters:
        - in: path
          name: type_key
          schema:
            title: Type Key
            type: string
          required: true
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RecordBatchIn'
        required: true
      responses:
        '200':
          description: OK
      security:
        - ScopedAPIKeyAuth: []
components:
  schemas:
    RecordBatchIn:
      properties:
        records:
          items:
            $ref: '#/components/schemas/RecordIn'
          title: Records
          type: array
        match_attribute:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Key of a unique attribute: update the record holding that value,
            create it otherwise
          title: Match Attribute
      required:
        - records
      title: RecordBatchIn
      type: object
    RecordIn:
      properties:
        values:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          description: Values by attribute key; a null value clears it
          title: Values
        links:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          description: >-
            Linked records by link type key: an id, a list of ids, or null.
            Replaces the records linked through that type.
          title: Links
      title: RecordIn
      type: object
  securitySchemes:
    ScopedAPIKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key

````

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