Avalara Batches API

Submit and manage batch transaction processing

Operations 8

GET /api/v2/companies/{companyId}/batches Avalara List Batches for a Company #
POST /api/v2/companies/{companyId}/batches Avalara Create a New Batch #
POST /api/v2/companies/{companyId}/batches/{id}/cancel Avalara CancelBatch #
POST /api/v2/companies/{companyId}/batches/transactions Avalara CreateTransactionBatch #
DELETE /api/v2/companies/{companyId}/batches/{id} Avalara DeleteBatch #
GET /api/v2/companies/{companyId}/batches/{id} Avalara GetBatch #
GET /api/v2/companies/{companyId}/batches/{batchId}/files/{id}/attachment Avalara DownloadBatch #
GET /api/v2/batches Avalara QueryBatches #

Documentation

Specifications

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/avalara-batches-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

avalara-batches-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Avalara Batches API
  version: '1.0'
  description: 'Operations tagged Batches across 2 of this provider''s published API definitions: avalara-avatax-rest-openapi.yml, avatax-apis-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://rest.avatax.com
  description: AvaTax Production
- url: https://sandbox-rest.avatax.com
  description: AvaTax Sandbox
- url: http://{{baseurl}}
tags:
- name: Batches
  description: Submit and manage batch transaction processing
paths:
  /api/v2/companies/{companyId}/batches:
    get:
      operationId: listBatches
      summary: Avalara List Batches for a Company
      tags:
      - Batches
      parameters:
      - $ref: '#/components/parameters/companyId'
      - $ref: '#/components/parameters/filter'
      - $ref: '#/components/parameters/top'
      - $ref: '#/components/parameters/skip'
      responses:
        '200':
          description: List of batches
      security:
      - basicAuth: []
      - bearerAuth: []
    post:
      operationId: createBatch
      summary: Avalara Create a New Batch
      tags:
      - Batches
      parameters:
      - $ref: '#/components/parameters/companyId'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/BatchModel'
      responses:
        '201':
          description: Batch created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BatchModel'
      security:
      - basicAuth: []
      - bearerAuth: []
    servers:
    - url: https://rest.avatax.com
      description: AvaTax Production
    - url: https://sandbox-rest.avatax.com
      description: AvaTax Sandbox
  /api/v2/companies/{companyId}/batches/{id}/cancel:
    post:
      tags:
      - Batches
      summary: Avalara CancelBatch
      description: 'Marks the in progress batch identified by this URL as cancelled.


        Only JSON batches can be cancelled. If you attempt to cancel a file batch, you will receive an error message.


        Only in progress batches can be cancelled. If you attempt to cancel a batch that its status is not Waiting or Processing, you will receive an error message.

        Cancelling an in progress batch does not delete any transactions that were created before the cancellation.


        Because the batch system processes with a degree of concurrency, and

        because of batch sizes in the queue vary, AvaTax API is unable to accurately

        predict when a batch will complete. If high performance processing is

        required, please use the

        CreateTransaction API.


        ### Security Policies


        * This API requires one of the following user roles: AccountAdmin, AccountOperator, BatchServiceAdmin, CompanyAdmin, CSPTester, SSTAdmin, SystemAdmin, SystemOperator, TechnicalSupportAdmin.'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              example: ''
      parameters:
      - name: X-Avalara-Client
        in: header
        schema:
          type: string
        description: Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/).
        example: AvaTax Postman Collection
      - name: companyId
        in: path
        schema:
          type: string
        required: true
      - name: id
        in: path
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
      security:
      - basicAuth: []
      operationId: postApiV2CompaniesByCompanyIdBatchesByIdCancel
      x-operation-id-source: derived
    servers:
    - url: http://{{baseurl}}
  /api/v2/companies/{companyId}/batches/transactions:
    post:
      tags:
      - Batches
      summary: Avalara CreateTransactionBatch
      description: 'Create a new transaction batch objects attached to this company.


        When a transaction batch is created, it is added to the AvaTax Batch v2 Queue and will be

        processed as quickly as possible in the order it was received. To check the

        status of a batch, fetch the batch and retrieve the results of the batch

        operation.


        Because the batch system processes with a degree of concurrency, and

        because of batch sizes in the queue vary, AvaTax API is unable to accurately

        predict when a batch will complete. If high performance processing is

        required, please use the

        CreateTransaction API.


        The maximum content length of the request body is limited to 28.6 MB. If this limit

        is exceeded, a 404 Not Found status will be returned (possibly with a CORS error if

        the API is called from a browser). In this situation, please split the request into

        smaller batches.


        ### Security Policies


        * This API requires one of the following user roles: AccountAdmin, AccountOperator, BatchServiceAdmin, CompanyAdmin, CSPTester, SSTAdmin, SystemAdmin, SystemOperator, TechnicalSupportAdmin.'
      requestBody:
        content:
          application/json:
            schema:
              type: object
              example:
                name: TestBatch-638274861770379744
                transactions:
                - createTransactionModel:
                    code: MyTransaction-638274861770379574
                    lines:
                    - number: '1'
                      quantity: 1
                      amount: 100
                      taxCode: PS081282
                      itemCode: Y0001
                      description: Yarn
                    type: SalesInvoice
                    companyCode: DEFAULT
                    date: '2023-08-13'
                    customerCode: ABC
                    purchaseOrderNo: 2023-08-13-001
                    addresses:
                      singleLocation:
                        line1: 2000 Main Street
                        city: Irvine
                        region: CA
                        country: US
                        postalCode: '92614'
                    commit: true
                    currencyCode: USD
                    description: Yarn
                - adjustTransactionModel:
                    companyCode: DEFAULT
                    transactionCode: MyTransaction-638274861770379574
                    documentType: SalesInvoice
                    adjustmentReason: PriceAdjusted
                    adjustmentDescription: Price drop before shipping
                    newTransaction:
                      code: MyTransaction-638274861770379574
                      lines:
                      - number: '1'
                        quantity: 1
                        amount: 90
                        taxCode: PS081282
                        itemCode: Y0001
                        description: Yarn
                      type: SalesInvoice
                      companyCode: DEFAULT
                      date: '2023-08-13'
                      customerCode: ABC
                      purchaseOrderNo: 2023-08-13-001
                      addresses:
                        singleLocation:
                          line1: 2000 Main Street
                          city: Irvine
                          region: CA
                          country: US
                          postalCode: '92614'
                      commit: true
                      currencyCode: USD
                      description: Yarn
                - createOrAdjustTransactionModel:
                    adjustmentReason: Other
                    adjustmentDescription: Test Description
                    createTransactionModel:
                      code: MyTransaction-638274861770379574
                      lines:
                      - number: '1'
                        quantity: 1
                        amount: 80
                        taxCode: PS081282
                        itemCode: Y0001
                        description: Yarn
                      type: SalesInvoice
                      companyCode: DEFAULT
                      date: '2023-08-13'
                      customerCode: ABC
                      purchaseOrderNo: 2023-08-13-001
                      addresses:
                        singleLocation:
                          line1: 2000 Main Street
                          city: Irvine
                          region: CA
                          country: US
                          postalCode: '92614'
                      commit: true
                      currencyCode: USD
                      description: Yarn
                - voidTransactionModel:
                    companyCode: DEFAULT
                    transactionCode: MyTransaction-638274861770379574
                    documentType: SalesInvoice
                    code: DocVoided
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      - name: X-Avalara-Client
        in: header
        schema:
          type: string
        description: Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/).
        example: AvaTax Postman Collection
      - name: companyId
        in: path
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
      security:
      - basicAuth: []
      operationId: postApiV2CompaniesByCompanyIdBatchesTransactions
      x-operation-id-source: derived
    servers:
    - url: http://{{baseurl}}
  /api/v2/companies/{companyId}/batches/{id}:
    delete:
      tags:
      - Batches
      summary: Avalara DeleteBatch
      description: 'Marks the batch identified by this URL as deleted.


        If you attempt to delete a batch that is being processed, you will receive an error message.

        Deleting a batch does not delete any transactions that were created by importing the batch.


        Because the batch system processes with a degree of concurrency, and

        because of batch sizes in the queue vary, AvaTax API is unable to accurately

        predict when a batch will complete. If high performance processing is

        required, please use the

        CreateTransaction API.


        ### Security Policies


        * This API requires one of the following user roles: BatchServiceAdmin, CSPAdmin, CSPTester, SSTAdmin, SystemAdmin, SystemOperator, TechnicalSupportAdmin.'
      parameters:
      - name: X-Avalara-Client
        in: header
        schema:
          type: string
        description: Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/).
        example: AvaTax Postman Collection
      - name: companyId
        in: path
        schema:
          type: string
        required: true
      - name: id
        in: path
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
      security:
      - basicAuth: []
      operationId: deleteApiV2CompaniesByCompanyIdBatchesById
      x-operation-id-source: derived
    get:
      tags:
      - Batches
      summary: Avalara GetBatch
      description: 'Get the batch object identified by this URL. A batch object is a large

        collection of API calls stored in a compact file.


        Use this endpoint to retrieve the results or check the status of a batch.


        When a batch is created, it is added to the AvaTax Batch Queue and will be

        processed as quickly as possible in the order it was received. To check the

        status of a batch, fetch the batch and retrieve the results of the batch

        operation.


        Because the batch system processes with a degree of concurrency, and

        because of batch sizes in the queue vary, AvaTax API is unable to accurately

        predict when a batch will complete. If high performance processing is

        required, please use the

        CreateTransaction API.


        ### Security Policies


        * This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, SystemOperator, TechnicalSupportAdmin, TechnicalSupportUser.'
      parameters:
      - name: X-Avalara-Client
        in: header
        schema:
          type: string
        description: Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/).
        example: AvaTax Postman Collection
      - name: companyId
        in: path
        schema:
          type: string
        required: true
      - name: id
        in: path
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
      security:
      - basicAuth: []
      operationId: getApiV2CompaniesByCompanyIdBatchesById
      x-operation-id-source: derived
    servers:
    - url: http://{{baseurl}}
  /api/v2/companies/{companyId}/batches/{batchId}/files/{id}/attachment:
    get:
      tags:
      - Batches
      summary: Avalara DownloadBatch
      description: 'Download a single batch file identified by this URL.


        ### Security Policies


        * This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, SystemOperator, TechnicalSupportAdmin, TechnicalSupportUser.'
      parameters:
      - name: X-Avalara-Client
        in: header
        schema:
          type: string
        description: Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/).
        example: AvaTax Postman Collection
      - name: companyId
        in: path
        schema:
          type: string
        required: true
      - name: batchId
        in: path
        schema:
          type: string
        required: true
      - name: id
        in: path
        schema:
          type: string
        required: true
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
      security:
      - basicAuth: []
      operationId: getApiV2CompaniesByCompanyIdBatchesByBatchIdFilesByIdAttachment
      x-operation-id-source: derived
    servers:
    - url: http://{{baseurl}}
  /api/v2/batches:
    get:
      tags:
      - Batches
      summary: Avalara QueryBatches
      description: 'Get multiple batch objects across all companies.


        A batch object is a large collection of API calls stored in a compact file.


        Search for specific objects using the criteria in the `$filter` parameter;

        full documentation is available on Filtering in REST .

        Paginate results using the `$top`, `$skip`, and `$orderby` parameters.


        When a batch is created, it is added to the AvaTax Batch Queue and will be

        processed as quickly as possible in the order it was received. To check the

        status of a batch, fetch the batch and retrieve the results of the batch

        operation.


        Because the batch system processes with a degree of concurrency, and

        because of batch sizes in the queue vary, AvaTax API is unable to accurately

        predict when a batch will complete. If high performance processing is

        required, please use the

        CreateTransaction API.


        ### Security Policies


        * This API requires one of the following user roles: AccountAdmin, AccountOperator, AccountUser, BatchServiceAdmin, CompanyAdmin, CompanyUser, CSPAdmin, CSPTester, SiteAdmin, SSTAdmin, SystemAdmin, SystemOperator, TechnicalSupportAdmin, TechnicalSupportUser.'
      parameters:
      - name: X-Avalara-Client
        in: header
        schema:
          type: string
        description: Identifies the software you are using to call this API. For more information on the client header, see [Client Headers](https://developer.avalara.com/avatax/client-headers/).
        example: AvaTax Postman Collection
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
      security:
      - basicAuth: []
      operationId: getApiV2Batches
      x-operation-id-source: derived
    servers:
    - url: http://{{baseurl}}
components:
  parameters:
    companyId:
      name: companyId
      in: path
      required: true
      schema:
        type: integer
      description: The numeric ID of the company
    skip:
      name: $skip
      in: query
      schema:
        type: integer
        default: 0
      description: Number of results to skip for pagination
    filter:
      name: $filter
      in: query
      schema:
        type: string
      description: OData filter expression for result filtering
    top:
      name: $top
      in: query
      schema:
        type: integer
        default: 1000
      description: Maximum number of results to return
  schemas:
    BatchModel:
      type: object
      properties:
        id:
          type: integer
        companyId:
          type: integer
        name:
          type: string
        type:
          type: string
          enum:
          - AvaCertUpdate
          - AvaCertUpdateAll
          - BatchMaintenance
          - CompanyLocationImport
          - DocumentImport
          - ExemptCertImport
          - ItemImport
          - SalesAuditExport
          - SstpTestDeckImport
          - TaxRuleImport
          - TransactionImport
          - UPCBulkImport
          - UPCBulkDelete
        status:
          type: string
          enum:
          - Waiting
          - SystemErrors
          - Cancelled
          - Completed
          - Creating
          - Deleted
          - Errors
          - Paused
          - Processing
          - ReadyToDelete
        recordCount:
          type: integer
        currentRecord:
          type: integer
        createdDate:
          type: string
          format: date-time
  securitySchemes:
    basicAuth:
      type: http
      scheme: basic
      description: Use your AvaTax username/password or accountId/licenseKey as basic auth credentials
    bearerAuth:
      type: http
      scheme: bearer
      description: OAuth 2.0 bearer token
externalDocs:
  description: AvaTax REST API v2 Documentation
  url: https://developer.avalara.com/api-reference/avatax/rest/v2/
x-refined-from:
- avalara-avatax-rest-openapi.yml
- avatax-apis-openapi.yml