API Introduction

In this section you will learn how to interact with our web service and connect with our ordering platform.
As you go through the documentation of the different endpoints, you may want to test how our API works and what can you get from it.

Table of Contents

Basic Concepts

The IFS web service is built on tried and true data transfer standards.
Our API is built on the Representational State Transfer (REST) protocol.
It is worth gleaning A basic understanding of REST if you do not already as it will make incorporating our web services much easier.

As with most REST services our endpoints often use the same parameters with your different GETs, POSTs, PUTs and DELETEs.
The specific characteristics are detailed on our API Reference Page

Roles

Information accesible within IFS is dependent on one or more business "roles" assigned to your user account. Your role name must be included in IFS urls when using API endpoint specific to your role (more on API URL conventions).

API URL Convention

API calls use a strict and predictable convention within their URLs. Documented below are the individual pieces to a web service URL.

URL Segments

Base URL

http://www.nwframing.com/IFS/api : This part of the URL is the base for every endpoint.

Role

http://www.nwframing.com/IFS/api/{role} :
Each API endpoint requires a your business's role name be inserted after the base URL. This role is assigned to you by NW Art + Framing.
The role provided is validated against your IFS account and is also used to get or post information to your organization.

API Call

http://www.nwframing.com/IFS/api/{role}/{api_call} : The API call specifies the action you are performing.

ID*

http://www.nwframing.com/IFS/api/{role}/{api_call}/{id*} :
Some api calls such getting a specific order's detail require an id to be supplied in the URL. ID typically represents an index identifier needed to call a specific data set.
For instance when getting an order's detail, id represents the order's order number.

The id url segment is skipped on calls that do not require it.

Here is an example of an API call to retrieve details for an order with the order number "10" where the organization (role) is named "Sprockets".

Authentication

The IFS webservice uses basic authentication to validate requests. Basic authentication requires a user name and password passed in the request header as a Base64 encoded string. Applying the encoding depends on your platform. An example of how to do this using cURL is provided below.

cURL example in PHP

This code demonstrates how to set basic authentication in the headers. This is only part of a request.

Additional Notes

Creating Orders

Submitted orders are imported in 30 minute intervals thus will not immediately display on your orders list.
Note that all SKU’s must be setup in our system prior to being submitted with an order. If an order is submitted with a SKU that isn’t on your list of SKU’s then it won’t be imported into our system.

Webhooks

Webhooks event driven HTTP callbacks that send data to a URL endpoint you define. Given the correct permissions, you can setup your webhooks by logging, navigating to the dashboard, clicking on your profile and then clicking the webhooks link.

Webhook Response Format

You can decide whether the data sent to your endpoint is formatted as JSON or XML.