API documentation (0.3.1)
Download OpenAPI specification:Download
The Enterspeed API are based on REST principles.
Before you start you will need to create an Enterspeed-account and set up a tenant (a property for your website). Here you can create
- A data source (provides you with an API key for the Ingest API).
- An environment client (provides you with an API key for the Delivery API).
- A domain (ensure the correct data gets fetched).
🎉 Have fun using our API. Make sure to contact us if you need any help. We're happy assist!
The Delivery API is what you use to GET
your data from Enterspeed to your frontend project. Before you can fetch your content from Enterspeed, you first need to create an Environment client which generates an API key. This is done under Settings --> Environment settings.
You can find an example of how to fetch data Umbraco & Next.js tutorial.
Get content by URL, IDs, or handles
Used to fetch views by a single URL and/or multiple IDs or handles in a single request.
Note: The maximum url length is 4096 characters
query Parameters
url | string Default: "" Example: url=https://enterspeed.com/about-us/ The URL to get data from. Maximum: 1 Required: false |
id | string Default: "" Example: id=gid://Environment/f0edd7b7-23dd-4177-a98a-313127601e97/Source/32ebdcab-ae19-4a71-a09e-a93257b807b7/Entity/4573/ContentPage Specific view ids to get data from. Maximum: unlimited |
handle | string Default: "" Example: handle=Navigation Specific handles to get data from. Handles will be returned in the views object and must be unique. Maximum: unlimited |
includeDuplicateViews | boolean Default: false Example: includeDuplicateViews=true By default, each view is returned only once. However, if you set includeDuplicateViews to true, the view will be returned for each matching requested handle |
header Parameters
X-Api-Key required | string Example: environment-1637c4d0-e878-4738-b866-152106a4f88c Api key to validate your environment. |
Responses
Response samples
- 200
- 422
{- "meta": {
- "status": 200
}, - "route": {
- "title": "Enterspeed",
- "logo": "/media-path/enterspeed.svg"
}, - "views": {
- "gid://Environment/f0edd7b7-23dd-4177-a98a-313127601e97/Source/32ebdcab-ae19-4a71-a09e-a93257b807b7/Entity/4573/BlogPostTile": {
- "title": "How to increase performance",
- "image": "/media-path/performance.jpg",
- "url": "/blog/how-to-increase-performance/"
}, - "Navigation": {
- "items": [
- {
- "text": "Contact us",
- "link": "/contact-us/"
}
]
}
}
}
Get content by IDs, or handles
The Post version of the Delivery API is used to fetch many view by IDs or handles.
Note: The maximum handles and ids combined in one request is limited to 1000
query Parameters
includeDuplicateViews | boolean Default: false Example: includeDuplicateViews=true By default, each view is returned only once. However, if you set includeDuplicateViews to true, the view will be returned for each matching requested handle |
header Parameters
X-Api-Key required | string Example: environment-1637c4d0-e878-4738-b866-152106a4f88c Api key to validate your environment. |
Content-Length required | number The length of the message body, in bytes (this header is automatically added by most clients). Note: The endpoint does not support |
Request Body schema: application/json
The ids or handles of the views to load
Both ids
and handles
are optional, but the request must contain at least one id or one handle.
Responses
Request samples
- Payload
{- "ids": [
- "gid://Environment/290a1654-e380-487e-8ea0-8f9f2fff589c/Source/01gh7ed9-6912-485b-9595-cd1e0c4ce89c/Entity/1234/View/content"
], - "handles": [
- "content-1234"
]
}
Response samples
- 200
- 422
{- "meta": {
- "status": 200
}, - "views": {
- "gid://Environment/290a1654-e380-487e-8ea0-8f9f2fff589c/Source/01gh7ed9-6912-485b-9595-cd1e0c4ce89c/Entity/1234/View/content": {
- "title": "How to increase performance",
- "image": "/media-path/performance.jpg",
- "url": "/blog/how-to-increase-performance/"
}, - "content-1234": {
- "title": "How to increase performance",
- "image": "/media-path/performance.jpg",
- "url": "/blog/how-to-increase-performance/"
}
}
}
The Ingest API is used to POST
your current data sources into Enterspeed. Before you can start ingesting data, you'll need to create a Data source inside Enterspeed, which generates an API key. This is done under Settings --> Data sources.
The Ingest API can also be used to DELETE
already ingested data from Enterspeed.
Save entity
Starting the process for saving the entity.
This endpoint can be used in two ways:
- Raw: The body contains the raw source entity and the required meta data is provided as header parameters.
- Simplified: The source entity is given
properties
of the body which also includes meta data.
path Parameters
originId required | string Example: 1 Id of the entity. Must be same format for all entities within the same source. Eg. integers, guids, etc. |
header Parameters
X-Api-Key required | string Example: source-90880177-e9a1-47b3-9a40-7b728a6bafd8 Api key to validate your source. |
X-Enterspeed-Type required | string Example: product The type or alias of the type of entity being send to process. Eg. blogList, blogPage, frontPage, etc. Only used for raw body |
X-Enterspeed-Url | string Example: /product-1 If the entity is routable send the URL. Skip if entity is not routable. Only used for raw body. Note: The URL needs to begin with a leading slash. |
X-Enterspeed-OriginParentId | string Example: 2 Allowed as null if no hierarchy exists. Only used for raw body |
X-Enterspeed-Redirects | string Example: /product-old,/product-very-old Comma separated list of URLs that redirects to the current page. Eg. https://enterspeed.com/product-1-old/ redirecting to https://enterspeed.com/product-1/. |
Content-Length required | number The length of the message body, in bytes (this header is automatically added by most clients). Note: The endpoint does not support |
Request Body schema: application/json
The entity to process
additional property | string or number or boolean or Array of arrays or object Property names:
|
Any of string Property names:
|
Responses
Request samples
- Payload
{- "name": "Official Enterspeed T-shirt",
- "price": 199.99,
- "inStock": true,
- "features": [
- {
- "name": "color",
- "value": "blue"
}, - {
- "name": "size",
- "value": "M"
}
], - "information": {
- "short": "Nice t-shirt",
- "long": "Nice t-shirt in cotton."
}
}
Response samples
- 200
{- "status": 200,
- "message": "Processing entity has begun"
}
The routes API is what you use to GET
all available URL routes for a specific environment, which can be helpful for SSG (Static Site Generation) or creating a sitemap.
Before you can fetch your routes from Enterspeed, you first need to create an Environment client which generates an API key. This is done under Settings --> Environment settings.
ℹ NOTE: The first
or last
parameter is required and must be set between 100 - 500 (e.g. first=250
). Both are not allowed at the same time.
Get Routes
Get all the routes for a specific environment.
query Parameters
first | number Example: first=100 Get the first of the paginated list, aka. get the list in ascending order. |
last | number Example: last=100 Get the last of the paginated list, aka. get the list in descending order. |
before | number The cursor to get data before, eg. previous page. |
after | number The cursor to get data after, eg. next page. |
header Parameters
X-Api-Key required | string Example: environment-1637c4d0-e878-4738-b866-152106a4f88c Api key to validate your environment. |
Responses
Response samples
- 200
- 422
{- "total": 16,
- "pageInfo": {
- "hasNextPage": true,
- "hasPreviousPage": false,
- "startCursor": "YmQ2YTY0NTgtZmU1Ny00MDZmLTlkMzgtNGNjMTczYWZmNzg2",
- "endCursor": "ZjJlNmY5NWYtOWM3ZS00N2I5LWI0N2ItMGY4M2YxYjMzZjQ1"
}, - "results": [
- {
- "url": "/about-us",
- "redirect": null,
- "updatedAt": "2021-05-21T10:22:21.262781Z"
}
]
}
Get Routes v2
Get all the routes for a specific environment with continuation token.
header Parameters
X-Continuation-Token | string Continuation token to get the next page. |
X-Api-Key required | string Example: environment-1637c4d0-e878-4738-b866-152106a4f88c Api key to validate your environment. |
Responses
Response samples
- 200
{- "continuationToken": "ZjJlNmY5NWYtOWM3ZS00N2I5LWI0N2ItMGY4M2YxYjMzZjQ1",
- "results": [
- {
- "url": "/",
- "redirect": null,
- "updatedAt": "2023-01-18T10:03:17.8862119Z"
}, - {
- "url": "/fairy-tales/the-leap-frog/",
- "redirect": "/old-url/the-leap-frog/",
- "updatedAt": "2023-07-03T13:23:41.0559142Z"
}
]
}