---
updatedAt: 2026-05-28T07:49:47.000Z
agentTools:
  projectIndex: https://finp2p-docs.ownera.io/llms.txt
---

# Get execution plan

Get execution plan

# OpenAPI definition

```json
{
  "openapi": "3.0.1",
  "info": {
    "title": "Operational API",
    "description": "This is the operational API reference for adapter development.",
    "termsOfService": "https://ownera.io/terms/",
    "contact": {
      "email": "support@ownera.io"
    },
    "version": "0.28"
  },
  "tags": [
    {
      "name": "execution",
      "description": "Execution plan related operational APIs"
    }
  ],
  "paths": {
    "/execution/{planId}": {
      "get": {
        "tags": [
          "execution"
        ],
        "summary": "Get execution plan",
        "description": "Get execution plan",
        "operationId": "getExecutionPlan",
        "parameters": [
          {
            "name": "planId",
            "in": "path",
            "description": "ID of the execution plan",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": ".*\\S.*",
              "x-autoMinLength": true
            }
          }
        ],
        "responses": {
          "200": {
            "description": "successful operation",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/execution"
                }
              }
            }
          },
          "400": {
            "description": "Bad Request",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 1002,
                      "message": "Invalid request format"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 3000,
                      "message": "Authentication error"
                    }
                  ]
                }
              }
            }
          },
          "403": {
            "description": "Forbidden",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 3400,
                      "message": "Access denied"
                    }
                  ]
                }
              }
            }
          },
          "404": {
            "description": "Not Found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 1100,
                      "message": "Resource not found"
                    }
                  ]
                }
              }
            }
          },
          "500": {
            "description": "Internal Server Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 2000,
                      "message": "General server error"
                    }
                  ]
                }
              }
            }
          },
          "502": {
            "description": "Bad Gateway",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 6101,
                      "message": "Failed to connect to external service"
                    }
                  ]
                }
              }
            }
          },
          "503": {
            "description": "Service Unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 2002,
                      "message": "Service unavailable"
                    }
                  ]
                }
              }
            }
          },
          "504": {
            "description": "Gateway Timeout",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/APIErrors"
                },
                "example": {
                  "errors": [
                    {
                      "code": 2003,
                      "message": "Gateway timeout"
                    }
                  ]
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "finIdAccount": {
        "type": "object",
        "required": [
          "type",
          "finId",
          "orgId",
          "custodian"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "finId"
            ]
          },
          "finId": {
            "$ref": "#/components/schemas/finId"
          },
          "orgId": {
            "$ref": "#/components/schemas/orgId"
          },
          "custodian": {
            "$ref": "#/components/schemas/custodian"
          }
        }
      },
      "execution": {
        "type": "object",
        "required": [
          "plan",
          "currentInstructionSequence",
          "approvals",
          "instructionsCompletionEvents",
          "executionPlanStatus",
          "creationTimestamp"
        ],
        "properties": {
          "plan": {
            "$ref": "#/components/schemas/executionPlan"
          },
          "approvals": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/executionPlanApproval"
            },
            "description": "Approvals/signatures of participants"
          },
          "creationTimestamp": {
            "type": "integer",
            "format": "int64",
            "description": "creation time in seconds since unix epoch"
          },
          "instructionsCompletionEvents": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/instructionCompletionEvent"
            },
            "description": "Represents a set of completed execution instructions"
          },
          "currentInstructionSequence": {
            "type": "integer",
            "format": "uint32",
            "description": "Sequence number of the current instruction"
          },
          "executionPlanStatus": {
            "type": "string",
            "enum": [
              "proposed",
              "approved",
              "rejected",
              "failed",
              "completed",
              "halted",
              "canceled"
            ],
            "description": "Current status of the execution plan"
          }
        }
      },
      "executionPlanApproval": {
        "type": "object",
        "required": [
          "organizationId",
          "signature",
          "digest"
        ],
        "properties": {
          "organizationId": {
            "type": "string",
            "description": "An Id of the organisation approved a plan",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "instructionCompletionEvent": {
        "type": "object",
        "required": [
          "instructionSequenceNumber",
          "signature"
        ],
        "properties": {
          "instructionSequenceNumber": {
            "type": "integer",
            "format": "uint32",
            "description": "Sequence number of the instruction involved"
          },
          "output": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/receiptOutput"
              },
              {
                "$ref": "#/components/schemas/instructionCompletionError"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "receipt": "#/components/schemas/receiptOutput",
                "error": "#/components/schemas/instructionCompletionError"
              }
            }
          }
        }
      },
      "receiptOutput": {
        "type": "object",
        "required": [
          "type",
          "id",
          "quantity",
          "details",
          "timestamp"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "receipt"
            ]
          },
          "id": {
            "type": "string",
            "description": "receipt id",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "source": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          },
          "destination": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          },
          "quantity": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "tradeDetails": {
            "$ref": "#/components/schemas/receiptTradeDetails"
          },
          "details": {
            "$ref": "#/components/schemas/receiptAssetDetails"
          },
          "operationType": {
            "type": "string",
            "enum": [
              "hold",
              "issue",
              "redeem",
              "release",
              "transfer",
              "move",
              "unknown"
            ]
          },
          "operationRef": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "timestamp": {
            "type": "integer"
          },
          "proof": {
            "$ref": "#/components/schemas/schemas_proofPolicy"
          }
        }
      },
      "noProofPolicy": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "noProofPolicy"
            ]
          }
        },
        "description": "no proof validation required for this policy"
      },
      "ownerId": {
        "type": "string",
        "description": "The Owner resource id",
        "pattern": "^[^:](?:.+):101:(?:.+)",
        "maxLength": 150,
        "example": "bank-x:101:511c1d7f-4ed8-410d-887c-a10e3e499a01"
      },
      "instructionCompletionError": {
        "type": "object",
        "required": [
          "type",
          "code",
          "message"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "error"
            ]
          },
          "code": {
            "type": "integer",
            "description": "1 for failure in regApps validation, 2 for failure in intent validation, 3 failure in settlement, 4 failure in signature verification"
          },
          "message": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "nonce": {
        "type": "string",
        "description": "32 bytes buffer (24 randomly generated bytes by the client + 8 bytes epoch timestamp seconds) encoded to hex:\n\n  const nonce = Buffer.alloc(32);\n  nonce.fill(crypto.randomBytes(24), 0, 24);\n\n  const nowEpochSeconds = Math.floor(new Date().getTime() / 1000);\n  const t = BigInt(nowEpochSeconds);\n  nonce.writeBigInt64BE(t, 24);\n",
        "x-allowEmpty": true
      },
      "APIError": {
        "type": "object",
        "required": [
          "code",
          "message"
        ],
        "properties": {
          "code": {
            "type": "integer",
            "description": "Error code indicating the specific failure - for more information see [API Errors](./api-error-codes-reference).\n"
          },
          "message": {
            "type": "string",
            "description": "A descriptive message providing context about the error.",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "APIErrors": {
        "type": "object",
        "required": [
          "errors"
        ],
        "properties": {
          "errors": {
            "type": "array",
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/APIError"
            }
          }
        }
      },
      "ledgerAssetIdentifierTypeCAIP-19": {
        "type": "object",
        "required": [
          "assetIdentifierType",
          "tokenId"
        ],
        "properties": {
          "assetIdentifierType": {
            "type": "string",
            "enum": [
              "CAIP-19"
            ],
            "description": "Classification type standards"
          },
          "network": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "tokenId": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "standard": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "ledgerAssetIdentifier": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/ledgerAssetIdentifierTypeCAIP-19"
          }
        ],
        "discriminator": {
          "propertyName": "assetIdentifierType",
          "mapping": {
            "CAIP-19": "#/components/schemas/ledgerAssetIdentifierTypeCAIP-19"
          }
        }
      },
      "finId": {
        "type": "string",
        "format": "finid",
        "description": "Existing owner hex representation of a secp256k1 public key 33 bytes compressed",
        "pattern": "^[0-9a-f]*$",
        "minLength": 64,
        "maxLength": 66,
        "x-autoMinLength": true
      },
      "receiptExecutionContext": {
        "type": "object",
        "required": [
          "executionPlanId",
          "instructionSequenceNumber"
        ],
        "properties": {
          "executionPlanId": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "instructionSequenceNumber": {
            "type": "integer"
          }
        }
      },
      "receiptTradeDetails": {
        "type": "object",
        "properties": {
          "intentId": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "intentVersion": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "executionContext": {
            "$ref": "#/components/schemas/receiptExecutionContext"
          }
        }
      },
      "field": {
        "type": "object",
        "description": "describing a field in the hash group",
        "required": [
          "name",
          "type",
          "value"
        ],
        "properties": {
          "name": {
            "type": "string",
            "description": "name of field",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "type": {
            "type": "string",
            "enum": [
              "string",
              "int",
              "bytes"
            ],
            "description": "type of field"
          },
          "value": {
            "type": "string",
            "description": "hex representation of the field value",
            "x-allowEmpty": true
          }
        }
      },
      "hashGroup": {
        "type": "object",
        "required": [
          "hash",
          "fields"
        ],
        "properties": {
          "hash": {
            "type": "string",
            "description": "hex representation of the hash group hash value",
            "x-allowEmpty": true
          },
          "fields": {
            "description": "list of fields by order they appear in the hash group",
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/field"
            }
          }
        }
      },
      "EIP712Domain": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "x-allowEmpty": true
          },
          "version": {
            "type": "string",
            "x-allowEmpty": true
          },
          "chainId": {
            "type": "integer",
            "format": "uint64"
          },
          "verifyingContract": {
            "type": "string",
            "format": "address",
            "x-allowEmpty": true
          }
        }
      },
      "EIP712TypeString": {
        "type": "string",
        "pattern": "^(?:$|0([^x].*)?|[^0].*)$",
        "x-allowEmpty": true
      },
      "EIP712TypeInteger": {
        "type": "integer"
      },
      "EIP712TypeBool": {
        "type": "boolean"
      },
      "EIP712TypeByte": {
        "type": "string",
        "pattern": "^0x[0-9a-fA-F]+$",
        "minLength": 3,
        "maxLength": 320
      },
      "EIP712TypedValue": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/EIP712TypeString"
          },
          {
            "$ref": "#/components/schemas/EIP712TypeInteger"
          },
          {
            "$ref": "#/components/schemas/EIP712TypeBool"
          },
          {
            "$ref": "#/components/schemas/EIP712TypeByte"
          },
          {
            "$ref": "#/components/schemas/EIP712TypeObject"
          },
          {
            "$ref": "#/components/schemas/EIP712TypeArray"
          }
        ]
      },
      "EIP712TypeObject": {
        "type": "object",
        "additionalProperties": {
          "$ref": "#/components/schemas/EIP712TypedValue"
        }
      },
      "EIP712TypeArray": {
        "type": "array",
        "items": {
          "$ref": "#/components/schemas/EIP712TypedValue"
        }
      },
      "EIP712TypeDefinition": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "x-allowEmpty": true
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/schemas_EIP712FieldDefinition"
            }
          }
        }
      },
      "EIP712Types": {
        "type": "object",
        "properties": {
          "definitions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/EIP712TypeDefinition"
            }
          }
        }
      },
      "signatureTemplate": {
        "type": "object",
        "oneOf": [
          {
            "$ref": "#/components/schemas/schemas_hashListTemplate"
          },
          {
            "$ref": "#/components/schemas/schemas_EIP712Template"
          }
        ],
        "discriminator": {
          "propertyName": "type",
          "mapping": {
            "hashList": "#/components/schemas/schemas_hashListTemplate",
            "EIP712": "#/components/schemas/schemas_EIP712Template"
          }
        }
      },
      "hashFunction": {
        "type": "string",
        "enum": [
          "unspecified",
          "sha3_256",
          "sha3-256",
          "blake2b",
          "keccak_256",
          "keccak-256"
        ],
        "description": "hash function types"
      },
      "walletAccount": {
        "type": "object",
        "required": [
          "type",
          "address"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "walletAccount"
            ]
          },
          "address": {
            "type": "string",
            "description": "address of the wallet",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "caip10Account": {
        "type": "object",
        "required": [
          "type",
          "network",
          "address"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "caip10Account"
            ]
          },
          "network": {
            "type": "string",
            "description": "CAIP-2 chain_id, e.g. \"eip155:1\", \"solana:5eykt4...\", \"hedera:mainnet\" (the same token used by the CAIP-19 asset identifier network)",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "address": {
            "type": "string",
            "description": "CAIP-10 account_address (chain-native address)",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true,
            "maxLength": 128
          }
        }
      },
      "custodialAccount": {
        "type": "object",
        "required": [
          "type",
          "provider",
          "vaultAccountId"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "custodialAccount"
            ]
          },
          "provider": {
            "type": "string",
            "description": "Custody provider discriminator, e.g. \"fireblocks\"",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "vaultAccountId": {
            "type": "string",
            "description": "Provider-internal account identifier (e.g. a Fireblocks vault account id)",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "assetId": {
            "type": "string",
            "description": "Optional. Narrows the custodial account to a specific asset/chain.",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "noneAccount": {
        "type": "object",
        "additionalProperties": false
      },
      "networkAccount": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/walletAccount"
          },
          {
            "$ref": "#/components/schemas/caip10Account"
          },
          {
            "$ref": "#/components/schemas/custodialAccount"
          },
          {
            "$ref": "#/components/schemas/noneAccount"
          }
        ]
      },
      "resourceId": {
        "type": "string",
        "description": "finp2p resource id format",
        "pattern": "^[^:](?:.+):(101|102|103|104|105):(?:.+)",
        "maxLength": 150,
        "example": "bank-x:101:9929ccaf-8967-4ba3-9198-a4b8e3128388"
      },
      "finp2pAsset": {
        "type": "object",
        "description": "describes asset information",
        "required": [
          "id",
          "ledgerIdentifier"
        ],
        "properties": {
          "id": {
            "$ref": "#/components/schemas/resourceId"
          },
          "ledgerIdentifier": {
            "$ref": "#/components/schemas/ledgerAssetIdentifier"
          }
        }
      },
      "executionPlanId": {
        "type": "string",
        "description": "The execution plan  resource id",
        "pattern": "^[^:](?:.+):106:(?:.+)",
        "example": "bank-x:106:511c1d7f-4ed8-410d-887c-a10e3e499a01"
      },
      "schemas_hashListTemplate": {
        "description": "ordered list of hash groups",
        "required": [
          "type",
          "hashGroups",
          "hash"
        ],
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "hashList"
            ]
          },
          "templateVersion": {
            "type": "integer",
            "minimum": 1,
            "description": "This version identifies the HashList template specification revision.\nWhen omitted, the verifier resolves the version from the\nrouter/ledger/asset-profile resolver chain.\n"
          },
          "hashGroups": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/hashGroup"
            }
          },
          "hash": {
            "type": "string",
            "description": "hex representation of the combined hash groups hash value",
            "x-allowEmpty": true
          }
        }
      },
      "schemas_EIP712FieldDefinition": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "x-allowEmpty": true
          },
          "type": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "schemas_EIP712Template": {
        "required": [
          "type",
          "domain",
          "message",
          "primaryType",
          "types",
          "hash"
        ],
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "EIP712"
            ]
          },
          "templateVersion": {
            "type": "integer",
            "minimum": 1,
            "description": "Template shape version. When omitted, the verifier resolves the\nversion from the router/ledger/asset-profile resolver chain.\nNot to be confused with EIP712Domain.version (the EIP-712\ncontract domain version). See pkg/signature/specs/eip712/ for\nversioned specs.\n"
          },
          "domain": {
            "$ref": "#/components/schemas/EIP712Domain"
          },
          "message": {
            "type": "object",
            "additionalProperties": {
              "$ref": "#/components/schemas/EIP712TypedValue"
            }
          },
          "types": {
            "$ref": "#/components/schemas/EIP712Types"
          },
          "primaryType": {
            "type": "string",
            "x-allowEmpty": true
          },
          "hash": {
            "type": "string",
            "description": "hex representation of template hash",
            "x-allowEmpty": true
          }
        }
      },
      "schemas_signature": {
        "type": "object",
        "required": [
          "signature",
          "template",
          "hashFunc"
        ],
        "description": "represent a signature template information",
        "properties": {
          "signature": {
            "type": "string",
            "description": "hex representation of the signature",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "template": {
            "$ref": "#/components/schemas/signatureTemplate"
          },
          "hashFunc": {
            "$ref": "#/components/schemas/hashFunction"
          }
        }
      },
      "schemas_signatureProofPolicy": {
        "type": "object",
        "required": [
          "type",
          "signature"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "signatureProofPolicy"
            ]
          },
          "signature": {
            "$ref": "#/components/schemas/schemas_signature"
          }
        }
      },
      "schemas_proofPolicy": {
        "type": "object",
        "discriminator": {
          "propertyName": "type",
          "mapping": {
            "signatureProofPolicy": "#/components/schemas/schemas_signatureProofPolicy",
            "noProofPolicy": "#/components/schemas/noProofPolicy"
          }
        },
        "oneOf": [
          {
            "$ref": "#/components/schemas/schemas_signatureProofPolicy"
          },
          {
            "$ref": "#/components/schemas/noProofPolicy"
          }
        ]
      },
      "amount": {
        "type": "string",
        "description": "the total number of units",
        "pattern": "^\\d+\\.?\\d*$",
        "maxLength": 150
      },
      "assetTerm": {
        "type": "object",
        "required": [
          "amount"
        ],
        "properties": {
          "amount": {
            "$ref": "#/components/schemas/amount"
          }
        }
      },
      "orgId": {
        "type": "string",
        "description": "Organization Id",
        "maxLength": 150,
        "pattern": "^[^:]*$",
        "x-go-type": "OrgIdValidatable",
        "minLength": 1,
        "x-autoMinLength": true
      },
      "custodian": {
        "type": "object",
        "required": [
          "orgId"
        ],
        "properties": {
          "orgId": {
            "$ref": "#/components/schemas/orgId"
          }
        }
      },
      "finp2pAssetAccount": {
        "type": "object",
        "description": "describes account and asset information",
        "required": [
          "account",
          "asset"
        ],
        "properties": {
          "account": {
            "$ref": "#/components/schemas/finIdAccount"
          },
          "asset": {
            "$ref": "#/components/schemas/finp2pAsset"
          },
          "networkAccount": {
            "$ref": "#/components/schemas/networkAccount",
            "description": "Optional. Investor network account to use for this leg. Must have been\npreviously bound via `POST /profiles/investor/{investorId}/account`.\nWhitelist-validated against `investor.data.accounts[org][asset]`\nbefore forwarding to the LA. Failure → error code 7351 (AccountNotWhitelistedErr, 400).\n"
          }
        }
      },
      "sourceAccountAssetInstruction": {
        "type": "object",
        "required": [
          "sourceAccount"
        ],
        "properties": {
          "sourceAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "sellingAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/sourceAccountAssetInstruction"
          }
        }
      },
      "noSettlementOption": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "noSettlement"
            ]
          }
        }
      },
      "unitValue": {
        "type": "string",
        "description": "A unit value represented as a string, the value is a decimal number",
        "pattern": "^\\d+(\\.\\d+)?$"
      },
      "partialSettlementOption": {
        "type": "object",
        "required": [
          "type",
          "unitValue"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "partialSettlement"
            ]
          },
          "unitValue": {
            "$ref": "#/components/schemas/unitValue"
          }
        }
      },
      "fullSettlementOption": {
        "type": "object",
        "required": [
          "type",
          "amount"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "fullSettlement"
            ]
          },
          "amount": {
            "$ref": "#/components/schemas/amount"
          }
        }
      },
      "settlementTerm": {
        "type": "object",
        "discriminator": {
          "propertyName": "type",
          "mapping": {
            "noSettlement": "#/components/schemas/noSettlementOption",
            "partialSettlement": "#/components/schemas/partialSettlementOption",
            "fullSettlement": "#/components/schemas/fullSettlementOption"
          }
        },
        "oneOf": [
          {
            "$ref": "#/components/schemas/noSettlementOption"
          },
          {
            "$ref": "#/components/schemas/partialSettlementOption"
          },
          {
            "$ref": "#/components/schemas/fullSettlementOption"
          }
        ]
      },
      "destinationAccountAssetInstruction": {
        "type": "object",
        "required": [
          "destinationAccount"
        ],
        "properties": {
          "destinationAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "sellingSettlementBase": {
        "type": "object",
        "required": [
          "settlementTerm"
        ],
        "properties": {
          "settlementTerm": {
            "$ref": "#/components/schemas/settlementTerm"
          },
          "settlementInstruction": {
            "$ref": "#/components/schemas/destinationAccountAssetInstruction"
          }
        }
      },
      "sellingSettlements": {
        "type": "array",
        "minItems": 1,
        "items": {
          "$ref": "#/components/schemas/sellingSettlementBase"
        }
      },
      "primarySale": {
        "type": "object",
        "required": [
          "type",
          "issuer",
          "asset",
          "settlement"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "primarySale"
            ]
          },
          "issuer": {
            "$ref": "#/components/schemas/ownerId"
          },
          "asset": {
            "$ref": "#/components/schemas/sellingAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sellingSettlements"
          }
        }
      },
      "buyingAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/destinationAccountAssetInstruction"
          }
        }
      },
      "buyingSettlementBase": {
        "type": "object",
        "required": [
          "settlementTerm"
        ],
        "properties": {
          "settlementTerm": {
            "$ref": "#/components/schemas/settlementTerm"
          },
          "settlementInstruction": {
            "$ref": "#/components/schemas/sourceAccountAssetInstruction"
          }
        }
      },
      "presignedSignaturePolicy": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "presignedPolicy"
            ]
          }
        }
      },
      "manualSignaturePolicy": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "manualPolicy"
            ]
          },
          "nonce": {
            "$ref": "#/components/schemas/nonce"
          }
        }
      },
      "buyingIntent": {
        "type": "object",
        "required": [
          "type",
          "buyer",
          "asset",
          "settlement"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "buyingIntent"
            ]
          },
          "buyer": {
            "type": "string",
            "description": "resource id of the buyer",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "asset": {
            "$ref": "#/components/schemas/buyingAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/buyingSettlementBase"
          },
          "settlements": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "legs"
              ],
              "properties": {
                "legs": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "$ref": "#/components/schemas/buyingSettlementBase"
                  }
                }
              }
            }
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              },
              {
                "$ref": "#/components/schemas/manualSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy",
                "manualPolicy": "#/components/schemas/manualSignaturePolicy"
              }
            }
          }
        }
      },
      "sellingIntent": {
        "type": "object",
        "required": [
          "type",
          "seller",
          "asset",
          "settlement"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "sellingIntent"
            ]
          },
          "seller": {
            "$ref": "#/components/schemas/ownerId"
          },
          "asset": {
            "$ref": "#/components/schemas/sellingAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sellingSettlements"
          },
          "settlements": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "legs"
              ],
              "properties": {
                "legs": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "$ref": "#/components/schemas/sellingSettlementBase"
                  }
                }
              }
            }
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              },
              {
                "$ref": "#/components/schemas/manualSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy",
                "manualPolicy": "#/components/schemas/manualSignaturePolicy"
              }
            }
          }
        }
      },
      "borrowerLenderAccountAssetInstruction": {
        "type": "object",
        "required": [
          "borrowerAccount",
          "lenderAccount"
        ],
        "properties": {
          "borrowerAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          },
          "lenderAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "loanIntentAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/borrowerLenderAccountAssetInstruction"
          }
        }
      },
      "loanIntentSettlementBase": {
        "type": "object",
        "required": [
          "settlementTerm"
        ],
        "properties": {
          "settlementTerm": {
            "$ref": "#/components/schemas/settlementTerm"
          },
          "settlementInstruction": {
            "$ref": "#/components/schemas/borrowerLenderAccountAssetInstruction"
          }
        }
      },
      "loanIntentSettlements": {
        "type": "array",
        "minItems": 1,
        "items": {
          "$ref": "#/components/schemas/loanIntentSettlementBase"
        }
      },
      "repaymentTerm": {
        "type": "object",
        "required": [
          "type",
          "closeAmount"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "repaymentTerm"
            ]
          },
          "closeAmount": {
            "$ref": "#/components/schemas/amount"
          },
          "interestRate": {
            "type": "string",
            "description": "indicative annual interest rate of the operation",
            "pattern": "^-?\\d*\\.?\\d*$",
            "maxLength": 150,
            "minLength": 1,
            "x-autoMinLength": true
          }
        }
      },
      "interestTerm": {
        "type": "object",
        "required": [
          "type",
          "interestRate"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "interestTerm"
            ]
          },
          "interestRate": {
            "type": "string",
            "description": "indicative annual interest rate of the operation",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "closeAmountTerm": {
        "type": "object",
        "required": [
          "type",
          "closeAmount"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "closeAmountTerm"
            ]
          },
          "closeAmount": {
            "$ref": "#/components/schemas/amount"
          }
        }
      },
      "loanConditions": {
        "type": "object",
        "oneOf": [
          {
            "$ref": "#/components/schemas/repaymentTerm"
          },
          {
            "$ref": "#/components/schemas/interestTerm"
          },
          {
            "$ref": "#/components/schemas/closeAmountTerm"
          }
        ],
        "discriminator": {
          "propertyName": "type",
          "mapping": {
            "repaymentTerm": "#/components/schemas/repaymentTerm",
            "interestTerm": "#/components/schemas/interestTerm",
            "closeAmountTerm": "#/components/schemas/closeAmountTerm"
          }
        }
      },
      "loanInstruction": {
        "type": "object",
        "required": [
          "openDate",
          "closeDate",
          "conditions"
        ],
        "properties": {
          "openDate": {
            "type": "integer",
            "format": "int64",
            "description": "date and time operation starts, in epoch (seconds)",
            "minimum": 0,
            "x-go-type-skip-optional-pointer": true
          },
          "closeDate": {
            "type": "integer",
            "format": "int64",
            "description": "date and time operation ends, in epoch (seconds)",
            "minimum": 0,
            "x-go-type-skip-optional-pointer": true
          },
          "conditions": {
            "$ref": "#/components/schemas/loanConditions"
          }
        }
      },
      "loanIntent": {
        "type": "object",
        "required": [
          "type",
          "creatorType",
          "borrower",
          "lender",
          "asset",
          "settlement"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "loanIntent"
            ]
          },
          "creatorType": {
            "type": "string",
            "enum": [
              "borrower",
              "lender"
            ]
          },
          "borrower": {
            "$ref": "#/components/schemas/ownerId"
          },
          "lender": {
            "$ref": "#/components/schemas/ownerId"
          },
          "asset": {
            "$ref": "#/components/schemas/loanIntentAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/loanIntentSettlements"
          },
          "loanInstruction": {
            "$ref": "#/components/schemas/loanInstruction"
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy"
              }
            }
          }
        }
      },
      "finp2pAssetAccountOptional": {
        "type": "object",
        "description": "describes account information",
        "required": [
          "asset"
        ],
        "properties": {
          "account": {
            "$ref": "#/components/schemas/finIdAccount"
          },
          "asset": {
            "$ref": "#/components/schemas/finp2pAsset"
          },
          "networkAccount": {
            "$ref": "#/components/schemas/networkAccount",
            "description": "Optional. Investor network account to use for this leg. Must have been\npreviously bound via `POST /profiles/investor/{investorId}/account`.\nWhitelist-validated against `investor.data.accounts[org][asset]`\nbefore forwarding to the LA. Failure → error code 7351 (AccountNotWhitelistedErr, 400).\n"
          }
        }
      },
      "optionalDestinationAccountAssetInstruction": {
        "type": "object",
        "required": [
          "destinationAccount"
        ],
        "properties": {
          "destinationAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccountOptional"
          }
        }
      },
      "redemptionAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/optionalDestinationAccountAssetInstruction"
          }
        }
      },
      "buyingSettlements": {
        "type": "array",
        "minItems": 1,
        "items": {
          "$ref": "#/components/schemas/buyingSettlementBase"
        }
      },
      "redemptionIntentConditions": {
        "properties": {
          "redemptionDuration": {
            "type": "string",
            "format": "duration",
            "description": "duration in ISO 8601 format (e.g., \"PT1H30M\" for 1 hour 30 minutes)",
            "pattern": "^P(\\d{1}Y)?(\\d{1,2}M)?(\\d{1,3}D)?(T(\\d{1,2}H)?(\\d{1,2}M)?(\\d{1,2}S)?)?$"
          }
        }
      },
      "redemptionIntent": {
        "type": "object",
        "required": [
          "type",
          "issuer",
          "asset",
          "settlement"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "redemptionIntent"
            ]
          },
          "issuer": {
            "$ref": "#/components/schemas/ownerId"
          },
          "asset": {
            "$ref": "#/components/schemas/redemptionAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/buyingSettlements"
          },
          "conditions": {
            "$ref": "#/components/schemas/redemptionIntentConditions"
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              },
              {
                "$ref": "#/components/schemas/manualSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy",
                "manualPolicy": "#/components/schemas/manualSignaturePolicy"
              }
            }
          }
        }
      },
      "optionalSourceAccountAssetInstruction": {
        "type": "object",
        "required": [
          "sourceAccount"
        ],
        "properties": {
          "sourceAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccountOptional"
          }
        }
      },
      "privateOfferIntentAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/optionalSourceAccountAssetInstruction"
          }
        }
      },
      "privateOfferIntent": {
        "type": "object",
        "required": [
          "type",
          "buyer",
          "seller",
          "asset",
          "settlement"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "privateOfferIntent"
            ]
          },
          "buyer": {
            "$ref": "#/components/schemas/ownerId"
          },
          "seller": {
            "$ref": "#/components/schemas/ownerId"
          },
          "asset": {
            "$ref": "#/components/schemas/privateOfferIntentAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sellingSettlements"
          },
          "settlements": {
            "type": "array",
            "items": {
              "type": "object",
              "required": [
                "legs"
              ],
              "properties": {
                "legs": {
                  "type": "array",
                  "minItems": 1,
                  "items": {
                    "$ref": "#/components/schemas/sellingSettlementBase"
                  }
                }
              }
            }
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              },
              {
                "$ref": "#/components/schemas/manualSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy",
                "manualPolicy": "#/components/schemas/manualSignaturePolicy"
              }
            }
          }
        }
      },
      "requestForTransferSendAssetInstruction": {
        "type": "object",
        "required": [
          "action"
        ],
        "properties": {
          "action": {
            "type": "string",
            "enum": [
              "send"
            ],
            "description": "Indicates whether the operation is to send or request money/asset."
          },
          "senderAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "requestForTransferRequestAssetInstruction": {
        "type": "object",
        "required": [
          "action"
        ],
        "properties": {
          "action": {
            "type": "string",
            "enum": [
              "request"
            ],
            "description": "Indicates whether the operation is to send or request money/asset."
          },
          "receiverAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "requestForTransferIntentAssetInstruction": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/requestForTransferSendAssetInstruction"
          },
          {
            "$ref": "#/components/schemas/requestForTransferRequestAssetInstruction"
          }
        ],
        "discriminator": {
          "propertyName": "action",
          "mapping": {
            "send": "#/components/schemas/requestForTransferSendAssetInstruction",
            "request": "#/components/schemas/requestForTransferRequestAssetInstruction"
          }
        }
      },
      "requestForTransferIntentAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/requestForTransferIntentAssetInstruction"
          }
        }
      },
      "requestForTransferIntent": {
        "type": "object",
        "required": [
          "type",
          "sender",
          "receiver",
          "asset"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "requestForTransferIntent"
            ]
          },
          "sender": {
            "$ref": "#/components/schemas/ownerId"
          },
          "receiver": {
            "$ref": "#/components/schemas/ownerId"
          },
          "asset": {
            "$ref": "#/components/schemas/requestForTransferIntentAsset"
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              },
              {
                "$ref": "#/components/schemas/manualSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy",
                "manualPolicy": "#/components/schemas/manualSignaturePolicy"
              }
            }
          }
        }
      },
      "moveDestination": {
        "type": "object",
        "description": "a Move destination asset. Superset of finp2pAsset (same required id + ledgerIdentifier), plus an optional pre-funded pool the Transfer drains into the destination for the hold-transfer-* variants.",
        "required": [
          "id",
          "ledgerIdentifier"
        ],
        "properties": {
          "id": {
            "$ref": "#/components/schemas/resourceId"
          },
          "ledgerIdentifier": {
            "$ref": "#/components/schemas/ledgerAssetIdentifier"
          },
          "fromSegregatedAccount": {
            "$ref": "#/components/schemas/finIdAccount"
          },
          "fromSegregatedAccountOwner": {
            "description": "owner of the pre-funded pool account — the Transfer seller (debited party) for receipts and regulation. Required when fromSegregatedAccount is set.",
            "$ref": "#/components/schemas/resourceId"
          }
        }
      },
      "moveAsset": {
        "type": "object",
        "description": "asset-level migration path declared by the source asset's organization; source + one-or-more destination assets (no quantity). Optional sourceToSegregatedAccount receives held source tokens on release (instead of burning); each destination may carry a pre-funded fromSegregatedAccount pool for the hold-transfer-* variants. The executor picks one destination at execution.",
        "required": [
          "sourceAsset",
          "destinationAssets"
        ],
        "properties": {
          "sourceAsset": {
            "$ref": "#/components/schemas/finp2pAsset"
          },
          "destinationAssets": {
            "type": "array",
            "minItems": 1,
            "items": {
              "$ref": "#/components/schemas/moveDestination"
            }
          },
          "sourceToSegregatedAccount": {
            "$ref": "#/components/schemas/finIdAccount"
          }
        }
      },
      "moveIntent": {
        "type": "object",
        "required": [
          "type",
          "asset"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "moveIntent"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/moveAsset"
          },
          "signaturePolicy": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/presignedSignaturePolicy"
              },
              {
                "$ref": "#/components/schemas/manualSignaturePolicy"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "presignedPolicy": "#/components/schemas/presignedSignaturePolicy",
                "manualPolicy": "#/components/schemas/manualSignaturePolicy"
              }
            }
          }
        }
      },
      "intent": {
        "type": "object",
        "oneOf": [
          {
            "$ref": "#/components/schemas/primarySale"
          },
          {
            "$ref": "#/components/schemas/buyingIntent"
          },
          {
            "$ref": "#/components/schemas/sellingIntent"
          },
          {
            "$ref": "#/components/schemas/loanIntent"
          },
          {
            "$ref": "#/components/schemas/redemptionIntent"
          },
          {
            "$ref": "#/components/schemas/privateOfferIntent"
          },
          {
            "$ref": "#/components/schemas/requestForTransferIntent"
          },
          {
            "$ref": "#/components/schemas/moveIntent"
          }
        ],
        "discriminator": {
          "propertyName": "type",
          "mapping": {
            "primarySale": "#/components/schemas/primarySale",
            "buyingIntent": "#/components/schemas/buyingIntent",
            "sellingIntent": "#/components/schemas/sellingIntent",
            "loanIntent": "#/components/schemas/loanIntent",
            "redemptionIntent": "#/components/schemas/redemptionIntent",
            "privateOfferIntent": "#/components/schemas/privateOfferIntent",
            "requestForTransferIntent": "#/components/schemas/requestForTransferIntent",
            "moveIntent": "#/components/schemas/moveIntent"
          }
        }
      },
      "assetIntent": {
        "type": "object",
        "required": [
          "start",
          "end",
          "intent"
        ],
        "properties": {
          "start": {
            "type": "integer",
            "format": "int64",
            "description": "start time for intent, in epoch (seconds)"
          },
          "end": {
            "type": "integer",
            "format": "int64",
            "description": "end time for intent, in epoch (seconds)"
          },
          "intent": {
            "$ref": "#/components/schemas/intent"
          }
        }
      },
      "ledgerAccountAsset": {
        "type": "object",
        "description": "describes account information",
        "required": [
          "finp2pAccount"
        ],
        "properties": {
          "finp2pAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          },
          "networkAccount": {
            "$ref": "#/components/schemas/networkAccount"
          }
        }
      },
      "holdInstruction": {
        "type": "object",
        "required": [
          "type",
          "source",
          "destination",
          "asset",
          "amount",
          "signature"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "hold"
            ]
          },
          "source": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "destination": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "amount": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "signature": {
            "$ref": "#/components/schemas/schemas_signature"
          }
        }
      },
      "releaseInstruction": {
        "type": "object",
        "required": [
          "type",
          "source",
          "destination",
          "asset",
          "amount"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "release"
            ]
          },
          "source": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "destination": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "amount": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "issueInstruction": {
        "type": "object",
        "required": [
          "type",
          "destination",
          "amount",
          "signature"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "issue"
            ]
          },
          "destination": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "amount": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "signature": {
            "$ref": "#/components/schemas/schemas_signature"
          }
        }
      },
      "transferInstruction": {
        "type": "object",
        "required": [
          "type",
          "source",
          "destination",
          "amount",
          "signature"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "transfer"
            ]
          },
          "source": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "destination": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "amount": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "signature": {
            "$ref": "#/components/schemas/schemas_signature"
          }
        }
      },
      "awaitInstruction": {
        "type": "object",
        "required": [
          "type",
          "waitUntil"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "await"
            ]
          },
          "waitUntil": {
            "type": "integer",
            "format": "uint64"
          }
        }
      },
      "revertHoldInstruction": {
        "type": "object",
        "required": [
          "type",
          "destination"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "revert-hold"
            ]
          },
          "source": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "destination": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          }
        }
      },
      "redemptionInstruction": {
        "type": "object",
        "required": [
          "type",
          "source",
          "destination",
          "amount",
          "signature"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "redemption"
            ]
          },
          "source": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "destination": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "amount": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "signature": {
            "$ref": "#/components/schemas/schemas_signature"
          }
        }
      },
      "executionPlanOperation": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/holdInstruction"
          },
          {
            "$ref": "#/components/schemas/releaseInstruction"
          },
          {
            "$ref": "#/components/schemas/issueInstruction"
          },
          {
            "$ref": "#/components/schemas/transferInstruction"
          },
          {
            "$ref": "#/components/schemas/awaitInstruction"
          },
          {
            "$ref": "#/components/schemas/revertHoldInstruction"
          },
          {
            "$ref": "#/components/schemas/redemptionInstruction"
          }
        ],
        "discriminator": {
          "propertyName": "type",
          "mapping": {
            "hold": "#/components/schemas/holdInstruction",
            "release": "#/components/schemas/releaseInstruction",
            "issue": "#/components/schemas/issueInstruction",
            "transfer": "#/components/schemas/transferInstruction",
            "await": "#/components/schemas/awaitInstruction",
            "redeem": "#/components/schemas/redemptionInstruction"
          }
        }
      },
      "executionInstruction": {
        "type": "object",
        "required": [
          "sequence",
          "organizations",
          "executionPlanOperation"
        ],
        "properties": {
          "sequence": {
            "type": "integer",
            "format": "uint32"
          },
          "organizations": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": ".*\\S.*",
              "x-autoMinLength": true
            }
          },
          "executionPlanOperation": {
            "$ref": "#/components/schemas/executionPlanOperation"
          },
          "timeout": {
            "type": "integer",
            "format": "int32"
          }
        }
      },
      "executionParticipant": {
        "type": "object",
        "required": [
          "organizationId",
          "roles"
        ],
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "roles": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "contributor",
                "observer"
              ]
            }
          }
        }
      },
      "investor": {
        "type": "object",
        "properties": {
          "investor": {
            "type": "string",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "role": {
            "type": "string",
            "enum": [
              "buyer",
              "seller",
              "lender",
              "borrower",
              "issuer"
            ]
          },
          "signature": {
            "$ref": "#/components/schemas/schemas_signature"
          }
        }
      },
      "sourceDestinationAccountLedgerAssetInstruction": {
        "type": "object",
        "required": [
          "sourceAccount",
          "destinationAccount"
        ],
        "properties": {
          "sourceAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          },
          "destinationAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "sourceDestinationExecuteAsset": {
        "type": "object",
        "properties": {
          "term": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "instruction": {
            "$ref": "#/components/schemas/sourceDestinationAccountLedgerAssetInstruction"
          }
        }
      },
      "issuanceContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "issuance"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          }
        }
      },
      "buyingContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "buying"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "selectedSettlement": {
            "type": "object",
            "required": [
              "legs"
            ],
            "properties": {
              "legs": {
                "type": "array",
                "minItems": 1,
                "items": {
                  "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
                }
              }
            }
          }
        }
      },
      "sellingContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "selling"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "selectedSettlement": {
            "type": "object",
            "required": [
              "legs"
            ],
            "properties": {
              "legs": {
                "type": "array",
                "minItems": 1,
                "items": {
                  "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
                }
              }
            }
          }
        }
      },
      "BorrowerLenderAccountLedgerAssetInstruction": {
        "type": "object",
        "required": [
          "borrowerAccount",
          "lenderAccount"
        ],
        "properties": {
          "borrowerAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          },
          "lenderAccount": {
            "$ref": "#/components/schemas/finp2pAssetAccount"
          }
        }
      },
      "loanExecuteAsset": {
        "type": "object",
        "required": [
          "assetInstruction",
          "assetTerm"
        ],
        "properties": {
          "assetTerm": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "assetInstruction": {
            "$ref": "#/components/schemas/BorrowerLenderAccountLedgerAssetInstruction"
          }
        }
      },
      "loanContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "loan"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/loanExecuteAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/loanExecuteAsset"
          },
          "instruction": {
            "$ref": "#/components/schemas/loanInstruction"
          }
        }
      },
      "transferContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "transfer"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          }
        }
      },
      "redeemContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "redeem"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          }
        }
      },
      "privateOfferContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "privateOffer"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "settlement": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          },
          "selectedSettlement": {
            "type": "object",
            "required": [
              "legs"
            ],
            "properties": {
              "legs": {
                "type": "array",
                "minItems": 1,
                "items": {
                  "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
                }
              }
            }
          }
        }
      },
      "requestForTransferContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "requestForTransfer"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/sourceDestinationExecuteAsset"
          }
        }
      },
      "moveExecuteAsset": {
        "type": "object",
        "description": "Execution-side asset of a Move: source/destination accounts plus the optional segregated-account legs that select the Move variant (a source segregated account implies Release; a destination pool implies Transfer).",
        "properties": {
          "term": {
            "$ref": "#/components/schemas/assetTerm"
          },
          "instruction": {
            "$ref": "#/components/schemas/sourceDestinationAccountLedgerAssetInstruction"
          },
          "sourceToSegregatedAccount": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          },
          "destinationFromSegregatedAccount": {
            "$ref": "#/components/schemas/ledgerAccountAsset"
          }
        }
      },
      "moveContractDetails": {
        "type": "object",
        "required": [
          "type"
        ],
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "move"
            ]
          },
          "asset": {
            "$ref": "#/components/schemas/moveExecuteAsset"
          }
        }
      },
      "contract": {
        "type": "object",
        "properties": {
          "investors": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/investor"
            }
          },
          "contractDetails": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/issuanceContractDetails"
              },
              {
                "$ref": "#/components/schemas/buyingContractDetails"
              },
              {
                "$ref": "#/components/schemas/sellingContractDetails"
              },
              {
                "$ref": "#/components/schemas/loanContractDetails"
              },
              {
                "$ref": "#/components/schemas/transferContractDetails"
              },
              {
                "$ref": "#/components/schemas/redeemContractDetails"
              },
              {
                "$ref": "#/components/schemas/privateOfferContractDetails"
              },
              {
                "$ref": "#/components/schemas/requestForTransferContractDetails"
              },
              {
                "$ref": "#/components/schemas/moveContractDetails"
              }
            ],
            "discriminator": {
              "propertyName": "type",
              "mapping": {
                "issuance": "#/components/schemas/issuanceContractDetails",
                "buying": "#/components/schemas/buyingContractDetails",
                "selling": "#/components/schemas/sellingContractDetails",
                "loan": "#/components/schemas/loanContractDetails",
                "transfer": "#/components/schemas/transferContractDetails",
                "redeem": "#/components/schemas/redeemContractDetails",
                "privateOffer": "#/components/schemas/privateOfferContractDetails",
                "requestForTransfer": "#/components/schemas/requestForTransferContractDetails",
                "move": "#/components/schemas/moveContractDetails"
              }
            }
          }
        }
      },
      "customMetadata": {
        "type": "object",
        "description": "Optional. A map of key:value string pairs for custom tracing, reconciliation, and business context. Opaque to the Router.\n",
        "additionalProperties": {
          "type": "string",
          "minLength": 1
        }
      },
      "executionPlan": {
        "type": "object",
        "required": [
          "id",
          "intent",
          "instructions",
          "participants",
          "contract"
        ],
        "properties": {
          "id": {
            "$ref": "#/components/schemas/executionPlanId"
          },
          "intent": {
            "$ref": "#/components/schemas/assetIntent"
          },
          "instructions": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/executionInstruction"
            }
          },
          "participants": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/executionParticipant"
            }
          },
          "contract": {
            "$ref": "#/components/schemas/contract"
          },
          "metadata": {
            "$ref": "#/components/schemas/customMetadata"
          }
        }
      },
      "receiptTransactionDetails": {
        "description": "Additional input and output details for UTXO supporting DLTs",
        "type": "object",
        "required": [
          "transactionId"
        ],
        "properties": {
          "transactionId": {
            "type": "string",
            "description": "Transaction id",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          },
          "operationId": {
            "type": "string",
            "description": "Operation id",
            "pattern": ".*\\S.*",
            "x-autoMinLength": true
          }
        }
      },
      "receiptAssetDetails": {
        "type": "object",
        "required": [
          "transactionDetails"
        ],
        "properties": {
          "transactionDetails": {
            "$ref": "#/components/schemas/receiptTransactionDetails"
          }
        }
      }
    }
  }
}
```