Own session context modification

Deleting an attribute from own session context

delete

Removes a specified attribute from a session context associated with the sessionId derived from the Authorization token used in the call. Recommended for performing calls from the storefront.

Note: Optimistic locking is not taken into account here.

Authorizations
Path parameters
tenantstring · min: 3 · max: 16Required

Your Emporix tenant's name.

Note: The tenant name should always be provided in lowercase.

Pattern: ^[a-z][a-z0-9]+$
attributeNamestringRequired

Name of the attribute that should be deleted from the session context.

Responses
204
The request was successful. The attribute has been deleted from the session context.
delete
DELETE /session-context/{tenant}/me/context/attributes/{attributeName} HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_OAUTH2_TOKEN
Accept: */*

No content

Adding a new attribute to a session context

post

Adds an attribute to a session context associated with the session-id derived from the Authorization token used in the call. Recommended for performing calls from the storefront.

Note: Optimistic locking is not taken into account here.

Authorizations
Path parameters
tenantstring · min: 3 · max: 16Required

Your Emporix tenant's name.

Note: The tenant name should always be provided in lowercase.

Pattern: ^[a-z][a-z0-9]+$
Body

Context attribute

keystringRequired

Additional context information key

valueone ofRequired

Additional context information value

objectOptional
or
stringOptional
Responses
201
The request was successful. The attribute was added to the session context.
application/json
Responsestring

Name of the created attribute.

post
POST /session-context/{tenant}/me/context/attributes HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 70

{
  "key": "additional attribute name",
  "value": "61079711ce0eb90861357045"
}
attr1

Was this helpful?