Fyndiq API v2 - documentation

Merchant uploading products

Basic concepts

API v2 is a hybrid between a REST and a feed API. Some resources are REST-like, but the product information transfer from the merchant to Fyndiq is carried out via a CSV feed.

Authentication and security

Feed

Even though it is not required for now, we strongly recommend to provide the product feed on an SSL-enabled URL (starting with "https://"). This ensures that the data is not eavesdropped on or tampered with when transferred to Fyndiq.

REST resources

The REST resources use HTTP basic access authentication. The username is the same as the merchant uses to login to the merchant pages. The password in the access authentication must be an API v2 token, which can be generated by the merchant at the merchant pages.

Settings and Notifications

This resource provides access to API settings.

All fields are optional, null is used to indicate that a feature is not used.
For example, if order_notification_url is set to null, no order notifications will be sent.

Field name Data type Example value Description
product_feed_url String (URL) "https://example.com/product_feed/" URL to your Product Feed.
product_feed_notification_url String (URL) "https://example.com/generate_feed/" URL where you want to receive Product Feed Notifications.
order_notification_url String (URL) "https://example.com/orders/" URL where you want to receive Order Notifcations.

Settings Resource

Retrieve Settings

Definition:

GET https://api.fyndiq.com/v2/settings/

Example request:

curl https://api.fyndiq.com/v2/settings/ \
    -u USERNAME:TOKEN

Example Response:

{
    "product_feed_url": "https://example.com/product_feed/",
    "product_feed_notification_url": null,
    "order_notification_url": "https://example.com/orders/"
}

Update Settings

In the following example request, we provide values for product_feed_url and order_notification_url.
But product_feed_notification_url is null, meaning Fyndiq will not send any Product Feed Notifications.

Definition:

PATCH https://api.fyndiq.com/v2/settings/

Example request:

curl https://api.fyndiq.com/v2/settings/ \
    -d '{"product_feed_url": "https://example.com/product_feed/", "product_feed_notification_url": null, "order_notification_url": "https://example.com/orders/"}' \
    -u USERNAME:TOKEN \
    -X PATCH

Request data:

{
    "product_feed_url": "https://example.com/product_feed/",
    "product_feed_notification_url": null,
    "order_notification_url": "https://example.com/orders/"
}

Response:

Returns HTTP status 204 No Content on success.
If the input data is invalid, it returns HTTP status 400 Bad Request with errors in the response body.

Notification System v2

In earlier versions of Fyndiq's API, there is a notification system tied to the API that can give updates on when new orders arrive or when a product has changed. We recommend that you do not use this system when integrating with API v2. In API v2 there is a new notification system that will notify about new orders. It will not notify about product changes, since Fyndiq does not change the merchant's product data any longer.

Product Feed Notifications

Fyndiq's Feed Reader will fetch the product feed on a regular interval, this assumes that you are keeping your feed updated continuously. A typical implementation for this is to use a scheduled task (for example, a cronjob), that regularly triggers a feed generation. If your platform for some reason does not support scheduled tasks, it's possible to use the Product Feed Notification from us as an alternative.

If a URL is present in the product_feed_notification_url field in the Settings Resource, Fyndiq will make a GET request to this URL every 10 minutes. The request will not contain any additional data; the merchant is expected to simply trigger a feed generation when the request is received.

Order Notifications

It is your responsibility to make sure that you regularly fetch new orders from the Order Resource.
A typical implementation for this is to have a cronjob that calls the Order Resource List View, using the min_date parameter.
However, we also provide Order Notifications as an additional feature, that are sent out immediately when an order is created, to enable even faster detection of new orders.
If a URL is present in the order_notfication_url field in the Settings Resource, we will make a GET request to this URL, with a order_id parameter.
When you receive an Order Notification, you can make a GET request to the Order Resource, for the given order_id to get the details.

Exporting Products

Feed Reader

Version 2 of Fyndiq's API uses a feed where you as a merchant or platform export product and article information to Fyndiq. This is the only way to give Fyndiq information about new or updated products – there are no REST resources for this in API v2. The feed must be a CSV feed that adheres to the requirements listed below.

Reading of the feed

The merchant provides a URL to Fyndiq where the feed can be found. The feed will be read at least once every hour by Fyndiq. Fyndiq will interpret the existence of a product in the feed and that has a number in stock of more than 0, as a request from the merchant to sell that product at Fyndiq.

If a product or article that was earlier in the feed would disappear, it will be removed from Fyndiq's system.

If the feed reader is unable to read a merchant's feed for an extended period of time (more than 3 hours), all the products from that merchant will be paused from selling until the feed can be successfully read again.

What products will be put out for sale?

Fyndiq has a number of checks that need to be passed before a product is put out for sale, so a product might never start selling for a number of different reasons such as:

CSV Dialect

Our CSV parser follows RFC 4180 as closely as possible.
However, the standard leaves some rules up to interpretation so there are rules specific to our system:

Example of valid CSV dialect:

"column-a",    "column-b",    "column-c"
"value in 1a", "value in 1b", "value in 1c"
"value in 2a", "value in 2b", "value in 2c containing escaped double quote "" in string"""
"value in 3a", "value in 3b", "value in 3c containing line breaks in
the quoted string"
"value in 4a", "value in 4b", "value in 4c"

Further Examples can be found on Wikipedia's article on CSV

Product and Article structure

Produced by OmniGraffle 6.2.1 2015-05-01 10:25:21 +0000 Canvas 1 Layer 1 id paused market title description brand category-id category-name category-fyndiq-id image-1-url image-1-identifier image-2-url image-2-identifier image-n-url image-n-identifier currency price oldprice portion comparison-unit vat-percent Pr oduct sku name quantity location identifi er -type identifi er -code pr operty-1-name pr operty-1-value pr operty-2-name pr operty-2-value pr operty-n-name pr operty-n-value Article

Each row in the feed represents a product-article combination according to the diagram. The product holds the main information that is shown in a product card on the site, and it is connected to one or more articles. The article represents a unique variation of a product. If the product has no variations at all, it will only have a single article. If the product has several variations, such as different colors or sizes, several articles can be created to accommodate this.

When reading the feed, if a product has several articles, the product information will be taken from the first of them. The feed reader will identify that several articles belong to the same product by looking at the product-id.


Please note, that this not only applies to fields like Product Title, Description and Images, but also to the Product Price. At the moment, it is not possible to combine articles with different prices into one product on Fyndiq. The price for all those combined articles would always be taken from the first of those combined articles in the feed.

SKU

The article SKU is very central, and must be provided on each line in the product feed. The article SKU must be globally unique within the feed and product registry on Fyndiq. The reason for this is that this is what will identify what article the merchant is updating on every feed reading. The article SKU also identifies the article that was sold when the merchant receives an order.

Fields

Below are the fields that can be used in the feed, along with descriptions, examples and requirements for the fields to validate.

Field descriptions

product-id

The merchant's product ID that ties together a group of articles. This must be unique for each product within the feed. Fyndiq will use it during the reading of the feed, but never save it. For example a feed containing 2 Fyndiq-products with 3 articles each could have the following product-id and article-sku values:

product-id article-sku
1 1
1 2
1 3
2 4
2 5
2 6
product-paused

If 1, it is a signal that this product should be paused from selling. Un-pause it again by submitting it in the feed with this flag set to 0.

product-category-id

The merchant's unique internal category id for this product. This is used to identify and map the merchant's categories to Fyndiq's. See category mapping system.

product-category-name

The merchant's unique internal category name associated with this product. This is used for displaying the category in Fyndiq's category mapping system.

product-category-fyndiq-id

Fyndiq's category id for this product. To learn about Fyndiq category ids to use for this field, see Category Tree Resource.

Please note that specifying a category using product-category-fyndiq-id will take precedence over the choices made for product-category-id and product-category-name fields.

product-brand-name

The name of the brand of this product. Fyndiq will try to match it with a brand in Fyndiq's database. If the brand is given, the field article_ean will be required.

product-title

The title of the product.

product-description

The description of the product. The product-description must not contain any HTML or other formatting.

product-market

What market the product is to be sold in. We do not support selling in different markets from the same merchant account.

product-currency

The currency of the values in "price" and "oldprice".

product-price

The price of the product. Must have dot (.) as decimal separator and include VAT.

product-oldprice

The old price of the product, i.e the price before selling on Fyndiq. If the merchant did not lower the price when starting to sell on Fyndiq, this should be set to equal to the "price" field. Must have dot (.) as decimal separator and include VAT.

product-vat-percent

The vat percentage of the price and oldprice (the price and oldprice must include VAT).

product-portion

The total weight or volume of the product (to be used in combination with product-comparison-unit).

product-comparison-unit

The unit of measurement for the weight or volume of the product (to be used in combination with product-portion).
Should be one of g, kg, ml, l, m, m2, m3, wash.

product-image-1-url

URL to the first product image (image-1). Supported formats are PNG, JPEG and GIF. The image must have a width of at least 200 pixels, and a height of at least 200 pixels.

product-image-1-identifier

The image identifier (for image-1) is a string denoting a unique instance of an image. When the contents of this field changes from the previous feed read, Fyndiq will fetch the corresponding image again. The field is needed for performance reasons – without it, every image would be downloaded once per hour, causing unnecessary network traffic and server load. Suggestions of values to use here are: A hash of the image contents, a timestamp of when the image was last updated, or a unique id representing a unique image.

product-image-2-url

URL to the second product image.

product-image-2-identifier

The image identifier (for image-2).

product-image-n-url

URL to the n'th product image. There can be a maximum of 50 images associated with the same product. So the maximum allowed column name here would be "product-image-50-url"

product-image-n-identifier

The image identifier for the n'th product image.

article-sku

The merchant's globally unique SKU id of this article. Together with market this identifies a unique article that is to be added or updated.

article-quantity

The quantity in stock of this article that is to be offered to Fyndiq at the reading of the feed.

article-name

The name of the article in the market's local language.

article-location

The merchant's location for the item in the warehouse. Will be shown on the delivery note to ease picking of items.

article-ean

Article's GTIN (EAN, UPC etc.) reference. As of September 1st 2017, required field for all branded products (field product-brand-name is given).

article-isbn

If the article has an ISBN code it should be supplied here.

article-mpn

If the article has an Manufacturer Part Number it should be supplied here.

article-eu-energy-class

The energy efficency class of the product according to EU Directive 2010/30/EU.

article-eu-energy-label-url

URL to picture of EU energy label.

article-eu-energy-datasheet-url

URL to EU energy data sheet of product.

article-property-1-name

The name of the first property associated with this article. If there are several properties they must be listed in as many 'property-name-n/property-value-n' column pairs as needed.

article-property-1-value

The value of the first property associated with this article.

article-property-2-name

The name of the second property associated with this article.

article-property-2-value

The value of the second property associated with this article.

article-property-n-name

The name of the n'th property associated with this article. There can be a maximum of 50 properties associated with the same article. So the maximum allowed column name here would be "article-property-50-name".

article-property-n-value

The value of the n'th property associated with this article.

Field validation rules

Field name Valid values Example value Required?
product-id String (1-32) 4711 Yes
product-paused 0 or 1 0 No
product-category-id String (1-32) 8432 No
product-category-name String (1-512) Sports>Ice Hockey>Helmets No
product-category-fyndiq-id Integer (See Category Tree Resource) 64 No
product-brand-name String (1-32) Adidas No
product-title String (5-64) Adidas soccer ball Yes
product-description String (10-4096) This is an amazing soccer ball. Yes
product-market SE SE Yes
product-currency SEK SEK Yes
product-price Decimal 199.50 Yes
product-oldprice Decimal 299.50 Yes
product-vat-percent Integer: 6, 12 or 25 25 Yes
product-portion Decimal 200.00 No
product-comparison-unit String (1-5). One of g,kg,ml,l,m,m2,m3,wash ml No
product-image-1-url String, valid URL http://img.example.com/p8328-a.jpg Yes
product-image-1-identifier String (1-42) ac33443422ee Yes
product-image-2-url String, valid URL http://img.example.com/p8328-b.jpg No
product-image-2-identifier String (1-42) 2233222 No
product-image-n-url String, valid URL http://img.example.com/p8328-n.jpg No
product-image-n-identifier String (1-42) p8328-n.jpg No
article-sku String (1-64) 2388BB-322 Yes
article-quantity Non-negative Integer (0-100000) 42 Yes
article-name String (1-30) Small Yes
article-location String (1-64) Shelf 43A No
article-ean String, valid GTIN code 5055664284261 Required for branded products
article-isbn String, valid ISBN code 978-1505297720 No
article-mpn String, Manufacturer Part Number A1688 No
article-eu-energy-class String. One of A+++, A++, A+, A, B, C, D, E, F, G A+++ No
article-eu-energy-label-url String. Valid URL, PNG or JPG http://img.example.com/p8328-n.jpg No
article-eu-energy-datasheet-url String. Valid URL, PNG, JPG or PDF No  
article-property-1-name String (1-64) Color No
article-property-1-value String (1-64) Red No
article-property-2-name String (1-64) Color No
article-property-2-value String (1-64) Red No
article-property-n-name String (1-64) Color No
article-property-n-value String (1-64) Red No

Category Mapping System

Fyndiq has a category mapping system, with which the merchant can easily map categories to Fyndiq's category tree. The usage is very simple for the merchant:

  1. The merchant supplies its own category-id and category-name for products according to the feed specification.
  2. Fyndiq's system will automatically detect and summarize what unique categories that exist in the merchant's feed and display these on the merchant pages.
  3. In this view in the merchant pages, the merchant can easily pick and map what Fyndiq category corresponds to each of the merchant's own categories.
  4. All products that have a defined mapping will automatically be categorized when they enter Fyndiq's system.

Example Feed

product-id,product-currency,article-quantity,product-description,product-price,product-oldprice,product-brand-name,article-location,product-image-1-url,product-image-1-identifier,product-title,product-vat-percent,product-market,article-sku,article-property-1-name,article-property-1-value,article-property-2-name,article-property-2-value,article-name
1,SEK,298,"Fashion has been creating well-designed collections since 2010. The brand offers feminine designs delivering stylish separates and statement dresses which have since evolved into a full ready-to-wear collection in which every item is a vital part of a woman's wardrobe. The result? Cool, easy, chic looks with youthful elegance and unmistakable signature style. All the beautiful pieces are made in Italy and manufactured with the greatest attention. Now Fashion extends to a range of accessories including shoes, hats, belts and more!",14.86,16.51,"Fashion Manufacturer",test,http://172.16.0.11/prestashop/img/p/1/1-large_default.jpg,1-1,"Faded Short Sleeves T-shirt",25,SE,demo_1,Size,S,Color,Orange,"Size: S, Color: Orange"

Category Tree Resource

Fyndiq category tree can be read to decide which id to use for product-category-fyndiq-id field.

Definition:

GET https://api.fyndiq.com/v2/categories/

Example request:

curl https://api.fyndiq.com/v2/categories/ \
    -u USERNAME:TOKEN

The response to that request will provide a list with all current categories on Fyndiq. Each category has Swedish and German values (name, path and URL), the Category ID and for child categories also the parent category's ID.

Example response:

{
  "categories": [
    {
      "url": {
        "de": "https://fyndiq.de/elektronik/",
        "sv": "https://fyndiq.se/elektronik/"
      },
      "parent_id": null,
      "path": {
        "de": "Elektronik",
        "sv": "Elektronik"
      },
      "id": 5,
      "name": {
        "de": "Elektronik",
        "sv": "Elektronik"
      }
    },
    {
      "url": {
        "de": "https://fyndiq.de/elektronik/alarmanlagen-personenalarm/",
        "sv": "https://fyndiq.se/elektronik/overfallslarm/"
      },
      "parent_id": 5,
      "path": {
        "de": "Elektronik -> Alarmanlagen & Personenalarm",
        "sv": "Elektronik -> Överfallslarm"
      },
      "id": 130,
      "name": {
        "de": "Alarmanlagen & Personenalarm",
        "sv": "Överfallslarm"
      }
    },
    {
      "url": {
        "de": "https://fyndiq.de/elektronik/batterien/",
        "sv": "https://fyndiq.se/elektronik/batterier/"
      },
      "parent_id": 5,
      "path": {
        "de": "Elektronik -> Batterien",
        "sv": "Elektronik -> Batterier"
      },
      "id": 131,
      "name": {
        "de": "Batterien",
        "sv": "Batterier"
      }
    }
  ]
}

Feed Report Resource

The latest Feed Report can be accessed through this resource.

It will always contain a field entries, where each item in the list has the fields timestamp, message and level.
Messages are ordered by timestamp in descending order.

The content in these reports is only intended for developers, it is not supposed to be shown to end users of an integration.

Definition:

GET https://api.fyndiq.com/v2/feed_report/

Example request:

curl https://api.fyndiq.com/v2/feed_report/ \
    -u USERNAME:TOKEN

Example response:

{
  "entries":[
    {
      "timestamp": "2015-09-29T16:55:04+02:00",
      "level":"info",
      "message":"Feed parsing successful. Products: 3. Articles: 6."
    },
    {
      "timestamp": "2015-09-29T16:50:02+02:00",
      "level":"info",
      "message":"Starting to process feed from URL: http://example.com/fyndiq-product-feed.csv."
    }
  ]
}

Product Info Resource

As soon as a product has been added through the Feed Reader, you will be able to read its current status through the Product Info Resource.

Product Info objects will always contain these fields:

Field name Data Type Example value Description
product_id String "631734" The value that you provided in the product-id column in your Product Feed.
for_sale String "FOR_SALE" Can be either "FOR_SALE" or "NOT_FOR_SALE".

Detail View

Used to fetch a single product info object, determined by the product ID in the URL.

Definition:

GET https://api.fyndiq.com/v2/product_info/748726/

Example request:

curl https://api.fyndiq.com/v2/product_info/55/ \
    -u USERNAME:TOKEN

Example response:

{
    "product_id": "748726",
    "for_sale": "FOR_SALE"
}

List View

Used to fetch multiple product info objects.
This view is paginated, and will always contain the fields next, previous, and results.
The fields next and previous will be either a link to the next or previous page, or null if there is not another page available in that direction.
The results field will always contain a list, with zero or more objects.
The page size is set to 50 items per page.

Definition:

GET https://api.fyndiq.com/v2/product_info/

Example request:

curl https://api.fyndiq.com/v2/product_info/ \
    -u USERNAME:TOKEN

Example response:

{
    "next": "https://api.fyndiq.com/v2/product_info/?cursor=cD0yMDE1LTA0LTIyKzE0JTNBNTglM0E0NA%3D%3D",
    "previous": null,
    "results": [
        {
            "product_id": "748726",
            "for_sale": "FOR_SALE"
        },
        {
            "product_id": "81735",
            "for_sale": "NOT_FOR_SALE"
        },
        {
            "product_id": "264758",
            "for_sale": "NOT_FOR_SALE"
        }
    ]
}

Importing Orders

Authentication

The resources below require authentication by HTTP Basic Auth. The username is the merchant's username at Fyndiq, and the password is the merchant's token that can be generated via the merchant pages at Fyndiq.

Order Resource

Order objects are very straight forward, and should match any general e-commerce system on a 1:1 scale.

Please note that the order_rows field will always be an array, containing one or more order row objects.
The sku field contains the value that you provided in the article-sku column in the Product Feed.

Detail View

Used to fetch a single order object, determined by the order ID in the URL.

Definition:

GET https://api.fyndiq.com/v2/orders/6/

Example request:

curl https://api.fyndiq.com/v2/orders/6/ \
    -u USERNAME:TOKEN

Example response:

{
    "id": 6,
    "created": "2014-12-01T14:25:32",
    "delivery_phone": "0701726627",
    "delivery_company": "Nilsco",
    "delivery_firstname": "Bengan",
    "delivery_lastname": "Aronsson",
    "delivery_address": "Nilsgatan 12",
    "delivery_co": "",
    "delivery_postalcode": "12344",
    "delivery_city": "Nilssala",
    "delivery_country": "Sweden",
    "delivery_country_code": "SE",
    "order_rows": [
        {
            "sku": "xyz-478",
            "quantity": 2,
            "unit_price_amount": "34.00",
            "unit_price_currency": "SEK",
            "vat_percent": "25.00"
        },
        {
            "sku": "kbk-123",
            "quantity": 1,
            "unit_price_amount": "28.00",
            "unit_price_currency": "SEK",
            "vat_percent": "25.00"
        }
    ],
    "delivery_note": "https://fyndiq.se/handlare/order/3/6/C3rxEw5gXdzGtVd8/pdf/"
}

List View

Used to fetch multiple orders.
This view is paginated, and will always contain the fields next, previous, and results.
The fields next and previous will be either a link to the next or previous page, or null if there is not another page available in that direction.
The results field will always contain a list, with zero or more objects.
The page size is set to 20 items per page.

Allows filtering by date via the min_date parameter.

Definition:

GET https://api.fyndiq.com/v2/orders/?min_date=2014-12-01 14:00:00

Example request:

curl https://api.fyndiq.com/v2/orders/?min_date=2014-12-01%2014:00:00 \
    -u USERNAME:TOKEN

Example response:

{
    "next": "https://api.fyndiq.com/v2/orders/?cursor=cD0yMDE1LTA0LTIyKzE0JTNBNTklM0EwNiZvPTE%3D&min_date=2014-12-01+14%3A00%3A00",
    "previous": null,
    "results": [
        {
            "id": 6,
            "created": "2014-12-01T14:25:32",
            "delivery_phone": "0701726627",
            "delivery_company": "Nilsco",
            "delivery_firstname": "Bengan",
            "delivery_lastname": "Aronsson",
            "delivery_address": "Nilsgatan 12",
            "delivery_co": "",
            "delivery_postalcode": "12344",
            "delivery_city": "Nilssala",
            "delivery_country": "Sweden",
            "delivery_country_code": "SE",
            "order_rows": [
                {
                    "sku": "xyz-478",
                    "quantity": 2,
                    "unit_price_amount": "34.00",
                    "unit_price_currency": "SEK",
                    "vat_percent": "25.00"
                },
                {
                    "sku": "kbk-123",
                    "quantity": 1,
                    "unit_price_amount": "28.00",
                    "unit_price_currency": "SEK",
                    "vat_percent": "25.00"
                }
            ],
            "delivery_note": "https://fyndiq.se/handlare/order/3/6/C3rxEw5gXdzGtVd8/pdf/"
        },
        {
            "...": "..."
        },
        {
            "...": "..."
        }
    ]
}

Marking single orders as handled

An order can be marked as handled by setting the field marked to true.

Definition:

PATCH https://api.fyndiq.com/v2/orders/1/

Example request:

curl https://api.fyndiq.com/v2/orders/1/ \
    -d '{"marked": true}' \
    -u USERNAME:TOKEN \
    -X PATCH

Marking multiple orders as handled

Multiple orders can be marked as handled by sending the following payload.

Definition:

POST https://api.fyndiq.com/v2/orders/marked/

{
    "orders": [
        {
            "id": 1,
            "marked": true
        },
        {
            "id": 2,
            "marked": true
        }
    ]
}

Delivery Note Resource

Returns a PDF document, containing one or multiple pages.
Each page is a delivery note, used for packing and shipping.

Takes a list of orders in the POST data.
The pages are returned in the same order as the order IDs in the input data.

There is a maximum of 300 orders per request.

Definition:

POST https://api.fyndiq.com/v2/delivery_notes/

Example request:

curl https://api.fyndiq.com/v2/delivery_notes/ \
    -d '{"orders": [{"order": 22398}, {"order": 75641}, {"order": 146462}, {"order": 8476}]}' \
    -u USERNAME:TOKEN \
    -X POST \
    > ~/delivery_notes.pdf

POST data in request body:

{
    "orders": [
        {"order": 22398},
        {"order": 75641},
        {"order": 146462},
        {"order": 8476}
    ]
}

Response:

The response is a PDF document.

The Content-Type header is application/pdf, and the response body consists of PDF data.

Sending Order Information

Package Resource

When orders are shipped as traceable parcels, tracking details for those parcels should be sent to Fyndiq in order to minimize the workload and also response times when customers have questions regarding the status of their orders. This can either be done manually on the merchant pages or directly through API v2. Also, certain campaigns on Fyndiq require that tracking details for each order are provided.

Package information can be sent to Fyndiq by making a request to the Packages Resource with the Fyndiq Order ID provided in the URL:

Definition:

PUT https://api.fyndiq.com/v2/packages/{order_id}/

Example request:

curl https://api.fyndiq.com/v2/packages/6/ \
    -u USERNAME:TOKEN

POST data in request body:

{
    "packages": [
        {
            "service": "postnord", 
            "tracking": "1234567890",
            "sku": ["SKU1", "SKU2"]
        },          
        {
            "service": "postnord",
            "tracking": "2345678901",
            "sku": ["SKU1"]
        }
    ]
}

An alternate way of using this resource is not providing the Fyndiq Order ID in the URL but rather add it to each package. By doing this, packages for several orders can be sent with only one request.

Definition:

POST https://api.fyndiq.com/v2/packages/

Example request:

curl https://api.fyndiq.com/v2/packages/ \
    -u USERNAME:TOKEN

POST data in request body:

{
    "packages": [
        {
            "service": "postnord",
            "tracking": "1234567890",
            "sku": ["SKU1"],
            "order": "1"
        },
        {
            "service": "postnord",
            "tracking": "2345678901",
            "sku": ["SKU2"],
            "order": "1"
        },        
        {
            "service": "postnord",
            "tracking": "3456789012",
            "sku": ["SKU3", "SKU4"],
            "order": "1"
        }
    ]
}

Response Codes:

Supported Delivery Services:

The following values are allowed for the service field (not case sensitive).
Requests with any other delivery service will fail.

User Agent

Usage

It is highly recommended each API request to be made with an UserAgent header complaint with the following definition:

Definition

PlatformName/PlatformVersion ModuleName/ModuleVersion (ModuleBuild)

The UserAgent must contain as detailed information as possible to help identify issues with the integration. It contains two main sections: platform and module information and the second one is optional.

UserAgent = platform [module]

The platform information includes the name of the integration platform followed by optional right slash character and version label.

platform = platform-name["/" platform-version]

The module information is optional and applicable if the integration is achieved by module additional to the main platform. It consists of the module name, followed by optional right slash character and version label, followed by optional module build version in brackets separated by space from the version.

module = module-name["/" module-version [" (" module-build ")"]]

Examples:

Magento/1.9.2 FyndiqMagentoModule/1.0.0 (ac332be)

SystemXTF/2.3.3

Glossary

CSV file
Comma-separated values is a text file format for tabular data. The format follows several simple rules and is easy to work with
SKU
Stock keeping unit is the unique identifier for each article. All SKUs must be unique, within a merchant feed. It is considered a bad practice to reuse SKU-s for discontinued products.
Article
Article (sometimes called variation or combination) is the selling unit which can actually be bought by a customer. Articles must have unique SKU
Product
A product is container for one or more articles. Articles belonging to a single product usually differ by one or more attributes e.g. different sizes for a shoe or different colors for a T-shirt. The articles contained in a product must all have the same Fyndiq price.

Published: 01 November 2017