Skip to main content

Help Center

Resource EndPoints

There are various endpoints available to retrieve and manipulate data. Be aware, however, each endpoint has criteria which must be met to make a successful request. Accessing the root path of the service will return available endpoints along with additional meta data for use prior to making additional requests: Root [application/vnd.adorbit+json]

{
    "root": "path-to-domain/",
    "login": "path-to-domain/login",
    "logout": "path-to-domain/logout",
     
    "companies": "path-to-domain/companies",
    "company": "path-to-domain/companies/{id}",
    "company-contacts": "path-to-domain/companies/{id}/contacts",
    "company-orders": "path-to-domain/companies/{id}/orders",
    "company-activities": "path-to-domain/companies/{id}/activities",
    "company-categories": "path-to-domain/companies/{companyId}/categories",
    "company-category": "path-to-domain/companies/{companyId}/categories/{id}",
    "company-attribute-values": "path-to-domain/companies/{companyId}/attribute-values",
    "company-attribute-value": "path-to-domain/companies/{companyId}/attribute-values/{id}",
    "company-attribute-fields": "path-to-domain/company-attribute-fields",
    "company-attribute-field": "path-to-domain/company-attribute-fields/{id}",
    "companyassets": "path-to-domain/companyassets",
     
    "contacts": "path-to-domain/contacts",
    "contact": "path-to-domain/contacts/{id}",
    "contact-activities": "path-to-domain/contacts/{id}/activities",
    "activities": "path-to-domain/activities",
    "activity": "path-to-domain/activities/{id}",
     
    "orders": "path-to-domain/orders",
    "order": "path-to-domain/orders/{id}",
     
    "subscribers": "path-to-domain/subscribers",
    "subscriber": "path-to-domain/subscribers/{id}",
    "subscriber-subscriptions": "path-to-domain/subscribers/{id}/subscriptions",
    "subscriber-creditcard": "path-to-domain/subscribers/{id}/creditcard",
    "subscriptions": "path-to-domain/subscriptions",
    "subscription": "path-to-domain/subscriptions/{id}",
    "subscriptionplans": "path-to-domain/subscriptionplans",

    "publications": "path-to-domain/publications",
    "publication": "path-to-domain/publications/{id}",
    "publication-issues": "path-to-domain/publications/{id}/issues",
    "issue": "path-to-domain/issues/{id}",

    "editorials": "path-to-domain/editorials",
    "editorial": "path-to-domain/editorials/{id}",

    "vendors": "path-to-domain/vendors",
    "vendor": "path-to-domain/vendors/{id}",
    "personnel": "path-to-domain/personnel/{id}",
    "self": "path-to-domain/"
}

It is important to start each session by making a request to the root of the service. No client should hard-code URIs to access resources since they may change over time. Using keys and the associated values within the response is the only way to guarantee request URIs will be valid.

Results Filtering

Several of the endpoints allow for query string variables that can be used to ‘filter’ the response. These filter variables can be combined as needed in a valid URI format. The following lists the end points that support different filters.

Activities

userid — numeric value of user assigned to activity (e.g. path-to-domain/activities?userid=1902)

date — exact date match of activity in YYYY-MM-DD format (e.g. path-to-domain/activities?date=2017-06-01)

sdate — start date range of activity in YYYY-MM-DD format (e.g. path-to-domain/activities?sdate=2017-06-01)

edate — end date range of activity in YYYY-MM-DD format (e.g. path-to-domain/activities?edate=2017-08-01)

Companies

company — wildcard match on company name (e.g. path-to-domain/companies?name=apple)

company_id — numeric value of company CID (e.g. path-to-domain/companies?company_id=439)

active — yes/no option indicating whether company is active or not (e.g. path-to-domain/companies?active=yes)

org_id — numeric value of organization/publisher (e.g. path-to-domain/companies?org_id=7)

organization — wildcard match on organization/publisher name (e.g. path-to-domain/companies?organization=corporate)

Contacts

company — wildcard match on company name (e.g. path-to-domain/companies?name=apple)

company_id — numeric value of company CID (e.g. path-to-domain/companies?company_id=439)

active — yes/no option indicating whether company is active or not (e.g. path-to-domain/companies?active=yes)

name — wildcard match on contact name (e.g. path-to-domain/contacts?name=smith)

email — wildcard math on contact email address (e.g. path-to-domain/contacts?email=rudy@adorbit.com)

phone — numeric wildcard match of contact phone numbers (e.g. path-to-domain/contacts?phone=78883333)

Editorials

title — wildcard match on editorial title (e.g. path-to-domain/editorials?title=nov+25)

pubid — numeric value of publication id editorial is assigned to (e.g. path-to-domain/editorials?pubid=3423)

issueid — numeric value of issue id editorial is assigned to (e.g. path-to-domain/editorials?issueid=194)

active — yes/no option indicating whether editorial is active or not (e.g. path-to-domain/editorials?active=yes)

Subscribers

name — wildcard match on subscriber name (e.g. path-to-domain/subscribers?name=smith)

email — wildcard math on subscriber email address (e.g. path-to-domain/subscribers?email=rudy@adorbit.com)

active — yes/no option indicating whether subscriber is active or not (e.g. path-to-domain/subscribers?active=yes)

Publications

name — wildcard match on publication name (e.g. path-to-domain/publications?name=city)

type — publication type, specifically ‘print’ for print publications or ‘online’ for digital publications (e.g. path-to-domain/publications?type=online)

Publication Issues

issue_period — indicate the issue timeframe, specifically ‘current’ for any issues within the last month or in the future and ‘past’ for any issues prior to one month ago (e.g. path-to-domain/publications/4/issues?issue_period=current)

Header Options

There are several header options that can be passed that allow for filtering the results returned.  These options are:

X-OPT-LIMIT — Sets the limit on records returns, similar to SQL “LIMIT”.  For example, “X-OPT-LIMIT:100” will return 100 rows of data.  The default LIMIT is set to 10 rows.

X-OPT-CHANGEDSINCE — Will filter results that have changed since a given time stamp.  For example, “X-OPT-CHANGEDSINCE: 2016-08-28 21:40:00” will return records changed since August 28th timestamp.  Please note that not all requests have a timestamp so it is conditionally relevant.

X-OPT-OFFSET — Will offset the results by the specified number of rows, similar to a SQL OFFSET statement.  For example, “X-OPT-OFFSET: 100” will offset the result by the offset*limit rows.  Using this allows the API’s to grab groups of data in ‘chunks’.  For example, if the LIMIT is set to 5 and the offset is 5, then it will be equivalent to getting rows 26-30.  The SQL executed is essentially “SELECT * FROM table LIMIT 25, 5”.