native_integrations

Description

This link relationship returns a collection of resources. You can easily paginate through this collection using the hypermedia links provided and the link relationships of first, prev, next, and last. Scroll down to view a representation of a single resource embedded within this collection.

Sandbox Example

You can interact with this resource and run actions against the sandbox API via our HAL Brower.

Actions

GET
View a list of native_integrations
POST
Create a new native_integration
HEAD
Get just the header response
OPTIONS
Get a response explaining which HTTP methods are supported

Example Representation

{
  "_links": {
    "curies": [
      {
        "name": "fx",
        "href": "https://api.foxycart.com/rels/{rel}",
        "templated": true
      }
    ],
    "self": {
      "href": "...",
      "title": "This Collection"
    },
    "first": {
      "href": "...?offset=0",
      "title": "First Page of this Collection"
    },
    "prev": {
      "href": "...?offset=0",
      "title": "Previous Page of this Collection"
    },
    "next": {
      "href": "...?offset=0",
      "title": "Next Page of this Collection"
    },
    "last": {
      "href": "...?offset=0",
      "title": "Last Page of this Collection"
    }
  },
  "_embedded": {
    "fx:native_integrations": [...]
  },
  "total_items": "5",
  "returned_items": 5,
  "limit": 20,
  "offset": 0
}
<?xml version="1.0" encoding="UTF-8"?>
<resource href="...">
  <link rel="self" href="..." title="This Collection"/>
  <link rel="first" href="...?offset=0" title="First Page of this Collection"/>
  <link rel="prev" href="...?offset=0" title="Previous Page of this Collection"/>
  <link rel="next" href="...?offset=0" title="Next Page of this Collection"/>
  <link rel="last" href="...?offset=0" title="Last Page of this Collection"/>
  <resource href="..." rel="https://api.foxycart.com/rels/native_integration">
  ...
  </resource>
  <total_items>5</total_items>
  <returned_items>5</returned_items>
  <limit>20</limit>
  <offset>0</offset>
</resource>
{
    "properties": {
        "total_items": "5",
        "returned_items": 5,
        "limit": 20,
        "offset": 0
    },
    "entities": [...],
    "links": [
        {
            "rel": [
                "self"
            ],
            "href": "..."
        },
        {
            "rel": [
                "first"
            ],
            "href": "...?offset=0"
        },
        {
            "rel": [
                "prev"
            ],
            "href": "...?offset=0"
        },
        {
            "rel": [
                "next"
            ],
            "href": "...?offset=0"
        },
        {
            "rel": [
                "last"
            ],
            "href": "...?offset=0"
        }
    ],
    "actions": [
    ]
}

Embedded Resource: native_integration

Description

A native integration represents a third party system natively integrated with Foxy which requires configruation settings and credentials.

Currently supported native integrations:

  • Avalara
    The config for Avalara should be a JSON string which includes the following values:
    • service_url: Your Avalara Service URL. If in test mode, it should be https://development.avalara.net. If in production, it should be https://avatax.avalara.net unless a different service_url has been provided to you by Avalara.
    • id: Your Avalara Account Number. Be sure to use either a development or production value based on service_url.
    • key: Your Avalara Licsense Key. Be sure to use either a development or production value based on service_url.
    • company_code: The Company Code configured in your Avalara Account. Be sure to use either a development or production value based on service_url.
    • use_ava_tax: (boolean) true or false to use Avalara for live tax rates.
    • create_invoice: (boolean) true or false. When using automatic tax calculations, after each completed transaction, if you'd like to commit those details to Avalara as a Committed Sales Invoice, check this box.
    • use_address_validation: (boolean) true or false. Validate customer addresses prior to completing the transaction which ensures you get more accurate tax and shipping rate calculations.
    • address_validation_countries: An array of country codes. Currently supports US and CA only.
  • TaxJar
    The config for TaxJar should be a JSON string which includes the following values:
    • api_token: Enter your SmartCalcs API Token obtained from TaxJar.
    • category_to_product_tax_code_mappings: (JSON) For each category in your store, you can set up a mapping to TaxJar's product tax codes to ensure the proper values are sent to TaxJar for the products in the categories you configure here.
    • create_invoice: (boolean) true or false. When using automatic tax calculations, after each completed transaction, if you'd like to commit those details to Avalara as a Committed Sales Invoice, check this box.
  • ONESOURCE
    The config for ONESOURCE should be a JSON string which includes the following values:
    • service_url: Please enter the ONESOURCE service URL you want to connect to.
    • external_company_id: A required external company ID mapping to the Determination company owning the audit data.
    • calling_system_number: A unique identifier for your ERP system. The combination of Calling System Number, Host System, and Unique Invoice Number form a unique key for an invoice in the Audit Database.
    • from_city: This city should match the postal code and country you have configured in your settings.
    • host_system: A unique name for your ERP system. The combination of Calling System Number, Host System, and Unique Invoice Number form a unique key for an invoice in the Audit Database.
    • company_role: The role the company plays in a given transaction: Buyer (B), Middleman (M), or Seller (S). Each role results in different transaction tax and reporting requirements.
    • part_number_product_option: If you use a custom product option name to specify your part number such as sku or isbn, enter that name here here. You can also set it to code to use the standard product code attribute.
    • onesource_audit_settings: When completing a transaction, use this setting to determine if the information sent to Onesource will be audited and reported. Valid values include capture_only, auth_and_capture, and never.

Sandbox Example

You can interact with this resource and run actions against the sandbox API via our HAL Brower.

Actions

GET
View a native_integration
PATCH
Update a native_integration (send only the properties you want to modify)
PUT
Replace a native_integration (send the entire representation)
DELETE
Delete a native_integration
HEAD
Get just the header response
OPTIONS
Get a response explaining which HTTP methods are supported

Properties

Property Description Type Constraints
provider The identifier string of this provider. String Required. avalara, taxjar, onesource
config A JSON string containing the configuration values and credentials for this native integration. JSON Required. 1000 characters or less.
date_created The date this resource was created. Date Read only
date_modified The date this resource was last modified. Date Read only

Example Representation

{
    "_links": {
        "curies": [
            {
                "name": "fx",
                "href": "https://api.foxycart.com/rels/{rel}",
                "templated": true
            }
        ],
        "self": {
            "href": "https://api.foxycart.com/native_integrations/4",
            "title": "This Native Integration"
        },
        "fx:store": {
            "href": "https://api.foxycart.com/stores/66",
            "title": "This Store"
        },
        "fx:taxes": {
            "href": "https://api.foxycart.com/stores/66/taxes?service_provider=avalara",
            "title": "Taxes using this Native Integration as the service provider"
        }
    },
    "provider": "avalara",
    "config": "{\"service_url\":\"https:\\/\\/development.avalara.net\",\"id\":\"12345678\",\"key\":\"ASDFJASDFKJASDFKJ\",\"company_code\":\"CompanyCode\",\"use_ava_tax\":true,\"create_invoice\":true,\"use_address_validation\":true,\"address_validation_countries\":[\"US\",\"CA\"]}",
    "date_created": "2016-03-24T11:02:40-0700",
    "date_modified": "2016-03-31T12:15:41-0700"
}
<?xml version="1.0" encoding="UTF-8"?>
<resource href="https://api.foxycart.com/native_integrations/4" rel="https://api.foxycart.com/rels/native_integration">
  <link rel="self" href="https://api.foxycart.com/native_integrations/4" title="This Native Integration"/>
  <link rel="https://api.foxycart.com/rels/store" href="https://api.foxycart.com/stores/66" title="This Store"/>
  <link rel="https://api.foxycart.com/rels/taxes" href="https://api.foxycart.com/stores/66/taxes?service_provider=avalara" title="Taxes using this Native Integration as the service provider"/>
  <provider>avalara</provider>
  <config>{&amp;quot;service_url&amp;quot;:&amp;quot;https:\/\/development.avalara.net&amp;quot;,&amp;quot;id&amp;quot;:&amp;quot;12345678&amp;quot;,&amp;quot;key&amp;quot;:&amp;quot;ASDFJASDFKJASDFKJ&amp;quot;,&amp;quot;company_code&amp;quot;:&amp;quot;CompanyCode&amp;quot;,&amp;quot;use_ava_tax&amp;quot;:true,&amp;quot;create_invoice&amp;quot;:true,&amp;quot;use_address_validation&amp;quot;:true,&amp;quot;address_validation_countries&amp;quot;:[&amp;quot;US&amp;quot;,&amp;quot;CA&amp;quot;]}</config>
  <date_created>2016-03-24T11:02:40-0700</date_created>
  <date_modified>2016-03-31T12:15:41-0700</date_modified>
</resource>
{
    "class": [
        "native_integration"
    ],
    "properties": {
        "provider": "avalara",
        "config": "{\"service_url\":\"https:\\/\\/development.avalara.net\",\"id\":\"12345678\",\"key\":\"ASDFJASDFKJASDFKJ\",\"company_code\":\"CompanyCode\",\"use_ava_tax\":true,\"create_invoice\":true,\"use_address_validation\":true,\"address_validation_countries\":[\"US\",\"CA\"]}",
        "date_created": "2016-03-24T11:02:40-0700",
        "date_modified": "2016-03-31T12:15:41-0700"
    },
    "links": [
        {
            "rel": [
                "self"
            ],
            "href": "https://api.foxycart.com/native_integrations/4"
        },
        {
            "rel": [
                "https://api.foxycart.com/rels/store"
            ],
            "href": "https://api.foxycart.com/stores/66"
        },
        {
            "rel": [
                "https://api.foxycart.com/rels/taxes"
            ],
            "href": "https://api.foxycart.com/stores/66/taxes?service_provider=avalara"
        }
    ],
    "actions": [
    ]
}

Conditional Link Relationsips

If this Native Integration is associated with other resources, a link relationship for those resources using this integration will show up. As an example, the Avalara integration will includes a taxes link relationship for all the taxes using this native integration as the service provider.

Zoomable Resources

This resource has no linked resources which can be "zoomed" in on, filtered and embedded within this resource.