> ## Documentation Index
> Fetch the complete documentation index at: https://docs.digitalasset.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Post apitoken standardv0registrars registrytransfer instructionv1 choice contextswithdraw

> Get the choice context to withdraw a transfer instruction.




## OpenAPI

````yaml /registry/apis/open-api-specs/utility-token-standard/v1/transfer-instruction-v1.yaml post /api/token-standard/v0/registrars/{registrarParty}/registry/transfer-instruction/v1/{transferInstructionId}/choice-contexts/withdraw
openapi: 3.0.0
info:
  title: transfer instruction off-ledger API
  description: >
    This is a fork of the official Open API spec defined as part of CIP 56.


    The only difference is in the URL prefix, which explicitly requires setting
    the `registrarParty` path parameter.


    This spec should not be used for client-side code generation, use the
    official one instead.
  version: 1.0.0
servers:
  - url: https://api.utilities.digitalasset.com
    description: MainNet
  - url: https://api.utilities.digitalasset-staging.com
    description: TestNet
  - url: https://api.utilities.digitalasset-dev.com
    description: DevNet
  - url: http://localhost:8080
    description: Local
security: []
paths:
  /api/token-standard/v0/registrars/{registrarParty}/registry/transfer-instruction/v1/{transferInstructionId}/choice-contexts/withdraw:
    post:
      tags:
        - public
      description: |
        Get the choice context to withdraw a transfer instruction.
      operationId: getTransferInstructionWithdrawContext
      parameters:
        - name: transferInstructionId
          description: The contract ID of the transfer instruction to withdraw.
          in: path
          required: true
          schema:
            type: string
        - name: registrarParty
          description: The registrar party.
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GetChoiceContextRequest'
      responses:
        '200':
          description: ok
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ChoiceContext'
        '400':
          $ref: '#/components/responses/400'
        '404':
          $ref: '#/components/responses/404'
        '500':
          $ref: '#/components/responses/500'
components:
  schemas:
    GetChoiceContextRequest:
      description: |
        A request to get the context for executing a choice on a contract.
      type: object
      properties:
        meta:
          description: >
            Metadata that will be passed to the choice, and should be
            incorporated

            into the choice context. Provided for extensibility.
          type: object
          additionalProperties:
            type: string
    ChoiceContext:
      description: >
        The context required to exercise a choice on a contract via an
        interface.

        Used to retrieve additional reference data that is passed in via
        disclosed contracts,

        which are in turn referred to via their contract ID in the
        `choiceContextData`.
      type: object
      properties:
        choiceContextData:
          description: The additional data to use when exercising the choice.
          type: object
        disclosedContracts:
          description: >
            The contracts that are required to be disclosed to the participant
            node for exercising

            the choice.
          type: array
          items:
            $ref: '#/components/schemas/DisclosedContract'
      required:
        - choiceContextData
        - disclosedContracts
    DisclosedContract:
      type: object
      properties:
        templateId:
          type: string
        contractId:
          type: string
        createdEventBlob:
          type: string
        synchronizerId:
          description: >
            The synchronizer to which the contract is currently assigned.

            If the contract is in the process of being reassigned, then a "409"
            response is returned.
          type: string
        debugPackageName:
          description: >
            The name of the Daml package that was used to create the contract.

            Use this data only if you trust the provider, as it might not match
            the data in the

            `createdEventBlob`.
          type: string
        debugPayload:
          description: >
            The contract arguments that were used to create the contract.

            Use this data only if you trust the provider, as it might not match
            the data in the

            `createdEventBlob`.
          type: object
        debugCreatedAt:
          description: >
            The ledger effective time at which the contract was created.

            Use this data only if you trust the provider, as it might not match
            the data in the

            `createdEventBlob`.
          type: string
          format: date-time
      required:
        - templateId
        - contractId
        - createdEventBlob
        - synchronizerId
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: string
  responses:
    '400':
      description: bad request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    '404':
      description: not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
    '500':
      description: Internal server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'

````