Get modal

View as Markdown
Retrieves the definition of a modal surfaced by a `MODAL_ACTION` on an assistant message, so that your application can render it natively. Every path parameter comes from that message. An entry in its `actions` array whose `type` is `MODAL_ACTION` carries the `modal_id` as `modal_action.modal_id`, and the message itself supplies `conversation_id`, `response_id`, and `message_id`. Assistant messages arrive from the list-messages endpoints, the get-response endpoint, and the `RESPONSE_OUTPUT_DELTA` and `RESPONSE_COMPLETED` streaming events. Conditional field rules are evaluated server-side, so every field arrives with its initial `visible`, `required`, and `read_only` state already resolved. Render the fields in the order they are returned. Fields whose value can change another field's state are flagged with `triggers_refresh`; call the refresh endpoint after one of those values changes. Keep the `options` list of every choice field in your own state. It is returned here and is not repeated on the refresh response.

Authentication

AuthorizationBearer

JWT bearer token authentication. Obtain an access token from the Moveworks auth endpoint and include it in the Authorization header as ‘Bearer <token>’.

Path parameters

conversation_idstringRequired

A base-62 identifier prefixed by a short resource type

response_idstringRequired

A base-62 identifier prefixed by a short resource type

message_idstringRequired

A base-62 identifier prefixed by a short resource type

modal_idstringRequired

Opaque modal identifier, taken from the modal_action.modal_id of the action that surfaced this modal. Pass it back exactly as received.

Headers

Assistant-NamestringRequired
The Moveworks assistant identifier that was configured for your organization.

Response headers

x-trace-idstringOptional
A unique identifier used to trace your request within the Moveworks system

Response

Modal retrieved successfully
modal_idstring

Opaque modal identifier, echoed from the MODAL_ACTION that surfaced this modal.

titlestring
Modal title to display.
fieldslist of objects
Fields in display order. Render them in the order returned.

Errors

401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
429
Too Many Requests Error
500
Internal Server Error