KeelsonDocs
    Judge Mode

    API reference Mandates

    Ask the user to change a mandate

    POST/v1/mandates/{id}/changes

    The agent asks its user for different limits, with a one-line note the user reads verbatim. The user may lower what is asked and approves with a passkey; the new mandate then replaces this one, whose hold is released. Nothing changes until the user signs. Poll GET /v1/connections/requests/{id} for the answer. An app acting for a user (mandates:request) asks only about a mandate that user approved for it.

    Path parameters

    idstringRequired

    Headers

    Content-Typeapplication/jsonRequired
    idempotency-keystringRequired
    Idempotency-KeystringRequired
    1 to 255 characters. A retry with the same key returns the first answer.

    Request body

    application/json

    notestringRequired
    Why the agent needs more room, in one line the user reads verbatim, e.g. 'Needs $40 more for shipping'.
    limitsobject
    The limits asked for; the mandate's own where left out.

    Responses

    • 201The user was asked; show the link and poll
    • 401No valid access token
    • 404No such mandate of an operator this client linked, or that the user approved for this app
    • 409The mandate has ended, or a change of it is already waiting for the user (change-pending, with its requestId)
    • 422The limits are invalid, or over the hosted operator's cap (hosted-cap)

    201 response

    request_idstringRequired
    user_codestringRequired
    verification_uri_completestringRequired
    expires_inintegerRequired
    intervalintegerRequired