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.
Interact with this resource
To interact with this resource and see it in the context of the API, you can utilise Postman or your Terminal/Console to perform requests. If you have a Foxy store, you can also use the API browser in the admin to interact with resources connected to your store.
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 configuration settings and credentials.
Currently supported native integrations:
-
Avalara
Theconfig
for Avalara should be a JSON string which includes the following values:
service_url
: Your Avalara Service URL. If in test mode, it should behttps://development.avalara.net
. If in production, it should behttps://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.enable_colorado_delivery_fee
: (Boolean) true or false to enable or disable the Colorado Delivery Feecreate_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.category_to_product_tax_code_mappings
: An associative array (aka hash, object) of Foxy category codes to AvaTax tax codes (which typically look something likePS081258
). If left empty, the category code will be sent to AvaTax instead.
-
TaxJar
Theconfig
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
Theconfig
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 assku
orisbn
, enter that name here here. You can also set it tocode
to use the standard product code attribute.product_order_priority
: The PRODUCT_CODE field in ONESOURCE is populated via the FoxyCart category code. The first shippable product will have the RELATED_LINE_NUMBER associated with it. To control which product is listed first, add a comma-separated list of FoxyCart category codes here based on the order priority you'd like. For example, if you puttest5, test1, test0
here, and all of those product category codes represent shippable items, thentest5
will be listed beforetest1
ortest0
and will have the RELATED_LINE_NUMBER shipping line applied to it.audit_settings
: When completing a transaction, use this setting to determine if the information sent to Onesource will be audited and reported. Valid values includecapture_only
,auth_and_capture
, andnever
.
-
Webhook
Theconfig
for Webhooks should be a JSON string which includes the following values:
-
service
: (String) Can be eitherjson
,legacy_xml
,webflow
orzapier
json
title
: (String) A descriptive title to give this webhook to identify it.encryption_key
: (String) This value is used as they key to encrypt the and verify the payload sent for the webhook.url
: (String) The absolute URL (beginning withhttps://
orhttp://
) that this webhook should be sent to.events
: (Array) A list of of the events that this webhook is subscribed to (currentlytransaction/created
andsubscription/cancelled
).version
: (Integer) The version of the webhook, currently1
.
title
: (String) A descriptive title to give this webhook to identify it.url
: (String) The absolute URL (beginning withhttps://
orhttp://
) that this webhook should be sent to.events
: (Array) A list of of the events that this webhook is subscribed to (currently onlytransaction/created
).version
: (Integer) The version of the webhook, currently1
.
site_id
: (String) The Site ID of your Webflow sitesite_name
: (String) The name of your Webflow site.collection_id
: (String) The ID of the collection that products are stored in.collection_name
: (String) The name of your products collection.sku_field_id
: (String) The ID of the code field in your products collection.sku_field_name
: (String) The name of the code field in your products collectioninventory_field_id
: (String) The ID of the inventory field in your products collection.inventory_field_name
: (String) The name of the inventory field in your products collection.auth
: (String) The OAuth Auth Bearer token for your Webflow site.events
: (Array) A list of of the events that this webhook is subscribed to (currently onlytransaction/created
).version
: (Integer) The version of the webhook, currently1
.
Note: Zapier service types are read only and can not be created or modified through the API. Zapier webhooks need to be created from zapier.com
event
: (String) The event this Zapier zap is subscribed to.url
: (String) The Zapier webhook subscription URL.
-
-
Custom Tax
Theconfig
for Custom Tax endpoint should be a JSON string which includes the following values:
url
: Please enter the Custom Tax service URL which we will use to add taxes to the checkout.
Interact with this resource
To interact with this resource and see it in the context of the API, you can utilise Postman or your Terminal/Console to perform requests. If you have a Foxy store, you can also use the API browser in the admin to interact with resources connected to your store.
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 , webhook |
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/5", "title": "This Native Integration" }, "fx:store": { "href": "https://api.foxycart.com/stores/66", "title": "This Store" } }, "provider": "webhook", "config": "{\"service\":\"json\",\"encryption_key\":\"1T6478TKJ9S5BHB73K0NTGDZ824X3HZ2\",\"title\":\"My JSON Webhook\",\"version\":1,\"url\":\"https:\\/\\/www.example.com\\/webhook.php\",\"events\":[\"transaction\\/created\"]}", "date_created": "2018-01-01T04:30:53-0700", "date_modified": "2018-01-01T04:30:53-0700" }, "_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\":false,\"address_validation_countries\":[],\"category_to_product_tax_code_mappings\":{\"1005\":\"PS081258\",\"955\":\"qweasz2\",\"956\":\"\",\"2425\":\"\"}}", "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>{&quot;service_url&quot;:&quot;https:\/\/development.avalara.net&quot;,&quot;id&quot;:&quot;12345678&quot;,&quot;key&quot;:&quot;ASDFJASDFKJASDFKJ&quot;,&quot;company_code&quot;:&quot;CompanyCode&quot;,&quot;use_ava_tax&quot;:true,&quot;create_invoice&quot;:true,&quot;use_address_validation&quot;:true,&quot;address_validation_countries&quot;:[&quot;US&quot;,&quot;CA&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 Relationships
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.