Anrok

App · 25 actions

Manage customers, tax calculations, transactions, exemption certificates, products and filings.

Actions

ActionWhat it does
Add product mappingAdd product mapping.
Archive customer certificateArchive customer certificate.
Create customerCreate customer.
Create customer certificateCreate customer certificate.
Create customer certificate requestCreate customer certificate request.
Create ephemeral transactionCreate ephemeral transaction.
Create negationCreate negation.
Create or update transactionCreate or update transaction.
Create productCreate product.
Get customerGet customer.
Get customer certificateGet customer certificate.
Get productGet product.
Get transactionGet transaction.
List customer certificatesList customer certificates.
List customersList customers.
List filing transaction IDsList filing transaction IDs.
List filing transactions with conversion ratesList filing transactions with conversion rates.
List filingsList filings.
List product mappingsList product mappings.
List product tax categoriesList product tax categories.
List productsList products.
List transactionsList transactions.
Resolve an addressResolve an address.
Validate tax IDsValidate tax IDs.
Void transactionVoid transaction.

Add product mapping

Add product mapping.

Inputs

Integration IDintegration_idtextRequired
Your unique integration ID.
Source IDsource_idtextRequired
Source product ID from billing system.
Target IDtarget_idtextRequired
Target product ID on Anrok. This product must already exist in Anrok.
Should overwriteshould_overwritetrue/false
Whether this request should override an existing `sourceId` mapping.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}

Archive customer certificate

Archive customer certificate.

Inputs

Certificatecertificate_idtextRequired
ID of the certificate.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}

Create customer

Create customer.

Inputs

IdidtextRequired
Your unique identifier for this customer. This must exactly match the customer ID that your billing system or integration will send on transactions, so that the customer's transactions and exemption certificates link up. For Anrok-native billing integrations, customer IDs are prefixed with the integration type (for example `stripe:cus_K39sWBu92Lo`). Customer IDs are unique across the entire seller account.
NamenametextRequired
The name of the customer. This is used for display purposes only.
Email addressemail_addresstext
Optional email address of the customer.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}

Create customer certificate

Create customer certificate.

Inputs

Customercustomer_idtextRequired
The Anrok customer ID used to link transactions for the same customer and to look up tax exemption certificates for a customer. This is typically the billing system's customer ID with a prefix to disambiguate. - If customerId is provided without customerName, that customer object must already exist in Anrok. - If both customerId and customerName are provided, the customer object will be created if it is not already present. - Customer IDs are unique across the entire seller account.
Customer namecustomer_nametext
The name of the customer. This is used for display purposes only.
Effective date begineffective_date_begindateRequired
Effective date of certificate
Exemption numberexemption_numbertext
Certificate exemption number. This is used for display purposes only.
Notesnotestext
Optional internal notes.
Typetypetext
The type of exemption the certificate represents. If omitted or null, no type is recorded. - `agricultural`: agricultural use. - `directPay`: direct pay permit. - `educational`: educational institution. - `energy`: energy-related exemption. - `governmentFederal`: federal government entity. - `governmentOther`: other government entity. - `governmentState`: state government entity. - `healthcare`: healthcare organization. - `manufacturing`: used in manufacturing. - `nativeAmericanTribal`: Native American tribal entity. - `nonprofit`: nonprofit organization. - `other`: other exemption type. - `religious`: religious organization. - `resale`: purchased for resale. - `researchDevelopment`: research and development use.One of: agricultural, directPay, educational, energy, governmentFederal, governmentOther, governmentState, healthcare, manufacturing, nativeAmericanTribal, and 5 more.
Certificate filecertificate_fileobjectRequired
Additional structured certificate file. Use the documented fields.
JurisesjuriseslistRequired
Jurisdictions for which certificate applies

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "id": "example"
  },
  "has_more": false,
  "next_cursor": null
}

Create customer certificate request

Create customer certificate request.

Inputs

Customercustomer_idtextRequired
The Anrok customer ID used to link transactions for the same customer and to look up tax exemption certificates for a customer. This is typically the billing system's customer ID with a prefix to disambiguate. - If customerId is provided without customerName, that customer object must already exist in Anrok. - If both customerId and customerName are provided, the customer object will be created if it is not already present. - Customer IDs are unique across the entire seller account.
Customer namecustomer_nametext
The name of the customer. This is used for display purposes only.
Email addressemail_addresstextRequired
The email address of the customer contact to send the certificate request to.
Send emailsend_emailtrue/false
Whether to email the certificate request to the recipient. If `false`, the request is created but no email is sent â you can share the resulting `requestLink` directly.
Auto approveauto_approvetrue/false
Whether to automatically approve the certificate once the customer submits it, instead of leaving the submission pending review in the Anrok dashboard. If a submission cannot be approved automatically, it falls back to the standard review flow.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "requestId": "example",
    "requestLink": "example"
  },
  "has_more": false,
  "next_cursor": null
}

Create ephemeral transaction

Create ephemeral transaction. Returns the full service response for the connected account.

Inputs

Line itemsline_itemslistRequired
The line items in the transaction.
Currency codecurrency_codetextRequired
Three letter ISO currency code (case insensitive).
Customer addresscustomer_addressobjectRequired
Additional structured customer address. Use the documented fields.
Customer namecustomer_nametext
The name of the customer. This is used for display purposes only.
Customer email addresscustomer_email_addresstext
The email address of the customer. This is used for display purposes only.
Customer tax IDscustomer_tax_idslist
Tax IDs for the customer receiving the product
Ship from addressship_from_addressobject
Additional structured ship from address. Use the documented fields.
Accounting dateaccounting_datedate
The date that this transaction occurred, for accounting purposes. Accounting date will typically correspond to the invoice date. This is used to determine which tax return the transaction belongs to.
Accounting timeaccounting_timetime
The time that this transaction occurred, for accounting purposes. If `accountingDate` is not provided, `accountingTime` is required to compute an accounting date for the transaction.
Accounting time zoneaccounting_time_zonetext
A âtz databaseâ string used to compute an accounting date from the request's `accountingTime`. The request cannot provide both an `accountingDate` and an `accountingTimeZone`. If `accountingTime` is provided without specifying an `accountingTimeZone`, the time zone configured on the seller account will be used.One of: UTC, America/New_York, America/Chicago, America/Denver, America/Los_Angeles, America/Anchorage, Pacific/Honolulu, Australia/Perth, Australia/Adelaide, Australia/Darwin, and 18 more.
Tax datetax_datedate
The date to use for tax calculations. If omitted, Anrok will use the accounting date.
User friendly IDuser_friendly_idtext
Optional. A human-readable ID for the transaction. This is typically the invoice number displayed in your billing system.
Tax amount addedtax_amount_addednumber
Optional. The total amount of tax already on this invoice, in the smallest denomination of the currency (e.g. cents). Not used for tax calculation; Anrok compares this against the tax it calculates in order to track tax discrepancies. If omitted, Anrok does not calculate tax discrepancies.
Customercustomer_idtext
The Anrok customer ID used to link transactions for the same customer and to look up tax exemption certificates for a customer. This is typically the billing system's customer ID with a prefix to disambiguate. - If customerId is provided without customerName, that customer object must already exist in Anrok. - Customer IDs are unique across the entire seller account.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "jurisSummaries": [],
    "lineItems": [],
    "preTaxAmount": "example",
    "taxAmountToCollect": 1,
    "taxComplianceMessage": "example"
  },
  "has_more": false,
  "next_cursor": null
}

Create negation

Create negation.

Inputs

Original transaction IDoriginal_transaction_idtextRequired
The ID of the transaction you want to negate.
New transaction IDnew_transaction_idtextRequired
The ID for the new negated transaction.
Original transaction expected versionoriginal_transaction_expected_versionnumber
The expected transaction version. The refund will fail if this is not the latest version of the transaction.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}

Create or update transaction

Create or update transaction.

Inputs

Line itemsline_itemslistRequired
The line items in the transaction.
Currency codecurrency_codetextRequired
Three letter ISO currency code (case insensitive).
Customer addresscustomer_addressobjectRequired
Additional structured customer address. Use the documented fields.
Customer namecustomer_nametext
The name of the customer. This is used for display purposes only.
Customer email addresscustomer_email_addresstext
The email address of the customer. This is used for display purposes only.
Customer tax IDscustomer_tax_idslist
Tax IDs for the customer receiving the product
Ship from addressship_from_addressobject
Additional structured ship from address. Use the documented fields.
Accounting dateaccounting_datedate
The date that this transaction occurred, for accounting purposes. Accounting date will typically correspond to the invoice date. This is used to determine which tax return the transaction belongs to.
Accounting timeaccounting_timetime
The time that this transaction occurred, for accounting purposes. If `accountingDate` is not provided, `accountingTime` is required to compute an accounting date for the transaction.
Accounting time zoneaccounting_time_zonetext
A âtz databaseâ string used to compute an accounting date from the request's `accountingTime`. The request cannot provide both an `accountingDate` and an `accountingTimeZone`. If `accountingTime` is provided without specifying an `accountingTimeZone`, the time zone configured on the seller account will be used.One of: UTC, America/New_York, America/Chicago, America/Denver, America/Los_Angeles, America/Anchorage, Pacific/Honolulu, Australia/Perth, Australia/Adelaide, Australia/Darwin, and 18 more.
Tax datetax_datedate
The date to use for tax calculations. If omitted, Anrok will use the accounting date.
User friendly IDuser_friendly_idtext
Optional. A human-readable ID for the transaction. This is typically the invoice number displayed in your billing system.
Tax amount addedtax_amount_addednumber
Optional. The total amount of tax already on this invoice, in the smallest denomination of the currency (e.g. cents). Not used for tax calculation; Anrok compares this against the tax it calculates in order to track tax discrepancies. If omitted, Anrok does not calculate tax discrepancies.
Customercustomer_idtext
The Anrok customer ID used to link transactions for the same customer and to look up tax exemption certificates for a customer. This is typically the billing system's customer ID with a prefix to disambiguate. - If customerId is provided without customerName, that customer object must already exist in Anrok. - If both customerId and customerName are provided, the customer object will be created if it is not already present. - Customer IDs are unique across the entire seller account.
IdidtextRequired
The ID of the new transaction. This must be unique across the entire seller account. This is typically the billing system's invoice ID with some prefix to disambiguate different systems.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "jurisSummaries": [],
    "lineItems": [],
    "preTaxAmount": "example",
    "taxAmountToCollect": 1,
    "taxComplianceMessage": "example",
    "version": 1
  },
  "has_more": false,
  "next_cursor": null
}

Create product

Create product.

Inputs

External IDexternal_idtextRequired
Your unique identifier for this product. The external ID may contain only alphanumeric characters, spaces, and `.-_:`. It must not contain leading or trailing spaces or consecutive spaces.
Tax category IDtax_category_idobjectRequired
Additional structured tax category id. Use the documented fields.
NamenametextRequired
The product's display name.
Descriptiondescriptiontext
Optional description of the product.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}

Get customer

Get customer. Returns the full service response for the connected account.

Inputs

Customercustomer_idtextRequired
The customer ID. URL-encode the ID if it contains special characters such as `:` or `/`.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "emailAddress": "example",
    "id": "example",
    "name": "example"
  },
  "has_more": false,
  "next_cursor": null
}

Get customer certificate

Get customer certificate. Returns the full service response for the connected account.

Inputs

Certificatecertificate_idtextRequired
ID of the certificate.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "createdTime": "example",
    "customerId": "example",
    "customerName": "example",
    "effectiveDateBegin": "example",
    "exemptionNumber": "example",
    "expiryDate": "example",
    "id": "example",
    "jurises": [],
    "notes": "example",
    "status": "active",
    "type": "agricultural"
  },
  "has_more": false,
  "next_cursor": null
}

Get product

Get product. Returns the full service response for the connected account.

Inputs

External IDexternal_idtextRequired
The external ID of the product.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "description": "example",
    "externalId": "example",
    "name": "example",
    "taxCategoryId": {
      "id": "example",
      "type": "standard"
    }
  },
  "has_more": false,
  "next_cursor": null
}

Get transaction

Get transaction. Returns the full service response for the connected account.

Inputs

Transactiontransaction_idtextRequired
ID of the transaction.

Outputs

dataobject
Normal transaction
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "anrokCreatedTime": "example",
    "anrokModifiedTime": "example",
    "body": {
      "accountingDate": "example",
      "addresses": [],
      "currencyCode": "example",
      "customer": {
        "id": "example",
        "name": "example"
      },
      "inputAmount": 1,
      "invoiceTotalAmountExpected": 1,
      "jurisSummaries": [],
      "lineItems": [],
      "preTaxAmount": "example",
      "taxAmountAdded": {
        "expected": 1,
        "seen": 1
      },
      "taxAmountDue": {
        "exclusive": "example",
        "inclusive": "example",
        "total": "example"
      },
      "taxDate": "example"
    },
    "id": "example",
    "sourceBillingSystem": {
      "integrationId": "example",
      "invoiceId": "example",
      "name": "example"
    },
    "type": "normal",
    "version": 1
  },
  "has_more": false,
  "next_cursor": null
}

List customer certificates

List customer certificates. Gets one page; to see more, run it again with the next page it gives.

Inputs

Filterfilterobject
Additional structured filter. Use the documented fields.
Limitlimitnumber
The maximum number of certificates to return.From 1 to 100.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page. Cannot be provided together with `filter`.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "certificates": [],
    "hasMore": false,
    "nextCursor": null
  },
  "has_more": false,
  "next_cursor": null
}

List customers

List customers. Gets one page; to see more, run it again with the next page it gives.

Inputs

Limitlimitnumber
The maximum number of customers to return.From 1 to 100.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "customers": [],
    "hasMore": false,
    "nextCursor": null
  },
  "has_more": false,
  "next_cursor": null
}

List filing transaction IDs

List filing transaction IDs. Gets one page; to see more, run it again with the next page it gives.

Inputs

Juris IDjuris_idtextRequired
The ID of the jurisdiction of the filing.
Juris filing IDjuris_filing_idtextRequired
The ID of the filing. This is a unique identifier for the filing within the jurisdiction.
Limitlimitnumber
The maximum number of transaction IDs to return.From 1 to 2500.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "nextCursor": null,
    "transactionIds": []
  },
  "has_more": false,
  "next_cursor": null
}

List filing transactions with conversion rates

List filing transactions with conversion rates. Gets one page; to see more, run it again with the next page it gives.

Inputs

Juris IDjuris_idtextRequired
The ID of the jurisdiction of the filing.
Juris filing IDjuris_filing_idtextRequired
The ID of the filing. This is a unique identifier for the filing within the jurisdiction.
Limitlimitnumber
The maximum number of transactions with conversion rates to return.From 1 to 1000.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "nextCursor": null,
    "transactionsWithConversionRates": []
  },
  "has_more": false,
  "next_cursor": null
}

List filings

List filings. Gets one page; to see more, run it again with the next page it gives.

Inputs

Filterfilterobject
Additional structured filter. Use the documented fields.
Limitlimitnumber
The maximum number of filings to return.From 1 to 100.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "filings": [],
    "hasMore": false,
    "nextCursor": ""
  },
  "has_more": false,
  "next_cursor": null
}

List product mappings

List product mappings. Returns the full service response for the connected account.

Inputs

Integration IDintegration_idtextRequired
Your unique integration ID.

Outputs

datalist
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": [],
  "has_more": false,
  "next_cursor": null
}

List product tax categories

List product tax categories. Returns the full service response for the connected account.

Inputs

None.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "productTaxCategories": []
  },
  "has_more": false,
  "next_cursor": null
}

List products

List products. Gets one page; to see more, run it again with the next page it gives.

Inputs

Limitlimitnumber
The maximum number of products to return.From 1 to 1000.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page.
Include default productsinclude_default_productstrue/false
Whether to include default products and default shipping products from any integrations in the response. When `false`, only regular products are returned.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "hasMore": false,
    "nextCursor": null,
    "products": []
  },
  "has_more": false,
  "next_cursor": null
}

List transactions

List transactions. Gets one page; to see more, run it again with the next page it gives.

Inputs

Filterfilterobject
Additional structured filter. Use the documented fields.
Limitlimitnumber
The maximum number of transactions to return.From 1 to 20.
Cursorcursortext
The cursor to use for pagination. This is the value of the `nextCursor` field returned from the previous page.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "hasMore": false,
    "nextCursor": "",
    "transactions": []
  },
  "has_more": false,
  "next_cursor": null
}

Resolve an address

Resolve an address. Returns the full service response for the connected account.

Inputs

Countrycountrytext
The country's full name or 2-letter ISO code
Line1line1text
The "delivery line" of the address
Citycitytext
City or town name
Regionregiontext
Other principal subdivision (i.e. province, state, county)
Postal codepostal_codetext
Postal code

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "jurisdictions": [],
    "resolvedAddress": {
      "city": "example",
      "country": "example",
      "line1": "example",
      "postalCode": "example",
      "region": "example"
    }
  },
  "has_more": false,
  "next_cursor": null
}

Validate tax IDs

Validate tax IDs. Returns the full service response for the connected account.

Inputs

Customer addresscustomer_addressobjectRequired
Additional structured customer address. Use the documented fields.
Customer tax IDscustomer_tax_idslistRequired
The tax IDs to validate.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {
    "jurises": []
  },
  "has_more": false,
  "next_cursor": null
}

Void transaction

Void transaction.

Inputs

Transactiontransaction_idtextRequired
ID of the transaction.
Transaction expected versiontransaction_expected_versionnumber
The expected transaction version. The void will fail if this is not the latest version of the transaction.

Outputs

dataobject
Data.
has_moretrue/false
Has more.
next_cursortext
Next cursor.
Example output
{
  "data": {},
  "has_more": false,
  "next_cursor": null
}

On this page