Experience Endpoints Actions

https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints

Below are the various requests that can be performed against the Experience Endpoints resource, as well as the expected parameters and the potential responses.

Get

Returns the experience endpoints for an application

Method And Url

GET https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints

Authentication

A valid api access token is required to access this endpoint. The token must include at least one of the following scopes: all.Application, all.Application.read, all.Organization, all.Organization.read, all.User, all.User.read, experienceEndpoints.*, or experienceEndpoints.get.

Request Path Components

Path Component Description Example
APPLICATION_ID ID associated with the application 575ec8687ae143cd83dc4a97

Request Query Parameters

Name Required Description Default Example
sortField N Field to sort the results by. Accepted values are: order, method, route, id, creationDate, requestCount, lastUpdated order sortField=order
sortDirection N Direction to sort the results by. Accepted values are: asc, desc asc sortDirection=asc
filterField N Field to filter the results by. Blank or not provided means no filtering. Accepted values are: method, route filterField=method
filter N Filter to apply against the filtered field. Supports globbing. Blank or not provided means no filtering. filter=my*route
experienceGroupId N Filter endpoints to those only in the specified group experienceGroupId=575ec8687ae143cd83dc4a97
requestCountDuration N If set, a count of recent requests is included on each endpoint for the duration requested (milliseconds) requestCountDuration=86400000
version N Return the experience endpoints belonging to this version develop version=develop

Request Headers

Name Required Description Default
Authorization Y The token for authenticating the request, prepended with Bearer

Curl Example

curl -H 'Content-Type: application/json' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer YOUR_API_ACCESS_TOKEN' \
    -X GET \
    https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints

Successful Responses

Code Type Description
200 Experience Endpoints Collection of experience endpoints

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if application was not found

Post

Create a new experience endpoint for an application

Method And Url

POST https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints

Authentication

A valid api access token is required to access this endpoint. The token must include at least one of the following scopes: all.Application, all.Organization, all.User, experienceEndpoints.*, or experienceEndpoints.post.

Request Path Components

Path Component Description Example
APPLICATION_ID ID associated with the application 575ec8687ae143cd83dc4a97

Request Headers

Name Required Description Default
Authorization Y The token for authenticating the request, prepended with Bearer

Request Body

The body of the request should be serialized JSON that validates against the Experience Endpoint Post schema. For example, the following would be a valid body for this request:

{
  "route": "/my/route/{id}",
  "method": "get",
  "access": "public"
}

Curl Example

curl -H 'Content-Type: application/json' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer YOUR_API_ACCESS_TOKEN' \
    -X POST \
    -d '{"route":"/my/route/{id}","method":"get","access":"public"}' \
    https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints

Successful Responses

Code Type Description
201 Experience Endpoint Successfully created experience endpoint

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if application was not found

Stats

Get statistics about endpoint requests

Method And Url

GET https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints/stats

Authentication

A valid api access token is required to access this endpoint. The token must include at least one of the following scopes: all.Application, all.Application.read, all.Organization, all.Organization.read, all.User, all.User.read, experienceEndpoints.*, or experienceEndpoints.stats.

Request Path Components

Path Component Description Example
APPLICATION_ID ID associated with the application 575ec8687ae143cd83dc4a97

Request Query Parameters

Name Required Description Default Example
statGrouping N Field to group the statistics by. Accepted values are: statusCode, endpointId, version, domain statusCode statGrouping=statusCode
duration N Duration in milliseconds 86400000 duration=86400000
end N End of time range in milliseconds since epoch 0 end=0
resolution N Resolution in milliseconds 3600000 resolution=3600000
versionFilter N Filters the stats to a particular experience version versionFilter=myVersion
domainFilter N Filters the stats to a particular experience domain or slug domainFilter=mycustomdomain.com
statusCodeFilter N Filters the stats to a particular status code statusCodeFilter=200
endpointIdFilter N Filters the stats to a particular endpoint endpointIdFilter=575ec8687ae143cd83dc4a98

Request Headers

Name Required Description Default
Authorization Y The token for authenticating the request, prepended with Bearer

Curl Example

curl -H 'Content-Type: application/json' \
    -H 'Accept: application/json' \
    -H 'Authorization: Bearer YOUR_API_ACCESS_TOKEN' \
    -X GET \
    https://api.app.wnology.io/applications/APPLICATION_ID/experience/endpoints/stats

Successful Responses

Code Type Description
200 Experience Endpoint Stats Statistics for endpoint requests

Error Responses

Code Type Description
400 Error Error if malformed request
404 Error Error if application was not found

Was this page helpful?


Still looking for help? You can also search the WEGnology Forums or submit your question there.