Versions Compared
Key
- This line was added.
- This line was removed.
- Formatting was changed.
Image RemovedImage Added
Example - Authentication command with remote image data
The authentication command in the Hermod API, POST /rest/command/authenticate
, contains a "description"
section.
Here is an example:
Code Block | ||
---|---|---|
| ||
"authCommand": { "params": { ... "description": [ ... { "content_type": "image/jpeg", "data": "BASE64 ENCODED IMAGE....", "content_encoding": "base64", "key": "auth_image", "description": "Verify that image is equal", "visible": true } ] } |
The content_type
and the data
element with base64-encoded data above can be replaced with a reference to remote data using the content provider instead.
Code Block | ||
---|---|---|
| ||
"authCommand": { "params": { ... "description": [ ... { "content_type": "application/hermod+content-id", "data": "AUTH:4018e11f-1209-45f5-ade7-e59004e10745", "key": "auth_image", "description": "Verify that image is equal", "visible": true } ] } |
It's then up to the content provider to return the correct base64 image data
, content_type
and content_encoding
.
Define authenticate image
An authenticate image can be defined in two ways: by including the actual data or by pointing to a content provider service where the image data is stored. This section describes what to set when using remote data.
Parameter | Value | Description |
---|---|---|
"content_type" | "application/hermod+content-id" | Content type to indicate that the data element has a reference to remote data. |
"data" | "<unique identifier>" Example: | Unique identifier for the image data in the content provider, which is defined by |
If you need to set up a content provider, see Requirements on content provider API.