render_ui_template
(**kwargs)¶Renders the UI template so that you can preview the worker's experience.
See also: AWS API Documentation
Request Syntax
response = client.render_ui_template(
UiTemplate={
'Content': 'string'
},
Task={
'Input': 'string'
},
RoleArn='string',
HumanTaskUiArn='string'
)
A Template
object containing the worker UI template to render.
The content of the Liquid template for the worker user interface.
[REQUIRED]
A RenderableTask
object containing a representative task to render.
A JSON object that contains values for the variables defined in the template. It is made available to the template under the substitution variable task.input
. For example, if you define a variable task.input.text
in your template, you can supply the variable in the JSON object as "text": "sample text"
.
[REQUIRED]
The Amazon Resource Name (ARN) that has access to the S3 objects that are used by the template.
The HumanTaskUiArn
of the worker UI that you want to render. Do not provide a HumanTaskUiArn
if you use the UiTemplate
parameter.
See a list of available Human Ui Amazon Resource Names (ARNs) in UiConfig.
dict
Response Syntax
{
'RenderedContent': 'string',
'Errors': [
{
'Code': 'string',
'Message': 'string'
},
]
}
Response Structure
(dict) --
RenderedContent (string) --
A Liquid template that renders the HTML for the worker UI.
Errors (list) --
A list of one or more RenderingError
objects if any were encountered while rendering the template. If there were no errors, the list is empty.
(dict) --
A description of an error that occurred while rendering the template.
Code (string) --
A unique identifier for a specific class of errors.
Message (string) --
A human-readable message describing the error.
Exceptions
SageMaker.Client.exceptions.ResourceNotFound