{"openapi":"3.0.0","info":{"title":"1Source Ledger API","description":"1Source Ledger API provides client access to the 1Source Ledger. You can find\nout more about 1Source at\n[https://equilend.com](https://equilend.com).\n\nThis specification is work in progress. The design is meant to model the securities lending life cycle in as clean a way as possible while being robust enough to easily translate to ISLA CDM workflows and data model.\n\nAPI specification is the intellectual property of EquiLend LLC and should not be copied or disseminated in any way.\n","termsOfService":"API Terms of Service\n\n*Last updated: March 27, 2026*\n\n### 1. Acceptance\nBy accessing or using this API, you (\"User\") agree to these Terms. If you are\nusing the API on behalf of an organization, you represent that you have authority\nto bind that organization.\n\n### 2. Permitted Use\nThe API is provided solely for the purpose of integrating your own systems or\nyour employer's systems with the Platform. Internal use and direct client\nintegrations are permitted under your subscription agreement.\n\n### 3. Commercial Third-Party Integration Services\nUse of this API to provide commercial integration, consulting, or implementation\nservices to third parties (\"Commercial Integration Services\") requires a separate\nwritten Partner Agreement with EquiLend. Absent such an agreement, you may not:\n- Use the API to build, configure, or deploy integrations on behalf of a paying third party\n- Sublicense, resell, or white-label API access or integration artifacts derived from it\n- Charge fees for services where the API or its outputs constitute a material\n  component of the deliverable\n\n### 4. Partner Program\nParties wishing to offer Commercial Integration Services must apply for\ncertification at https://ops1s.equilend.com. Certified Partners are subject to\nrevenue-sharing terms set forth in the Partner Agreement, which may include\na fee or percentage of integration contract value.\n\n### 5. Proprietary Materials\nAll SDKs, connector libraries, reference implementations, session/state schemas,\nand integration architecture documentation provided by EquiLend are\nproprietary and licensed, not sold. You may not sublicense, copy, or distribute\nthese materials without written consent.\n\n### 6. Restrictions\nYou may not:\n- Reverse engineer or replicate the Platform's session or state management\n  mechanisms for commercial resale\n- Use the API in a manner designed to circumvent applicable fees or\n  licensing requirements\n- Permit unauthorized third parties to access the API using your credentials\n\n### 7. Enforcement and Termination\nViolation of these Terms may result in immediate suspension of API access\nwithout notice. EquiLend reserves the right to audit usage logs\nto verify compliance.\n\n### 8. Modifications\nEquiLend may update these Terms at any time. Continued use of the API\nafter notice of changes constitutes acceptance.\n\n### 9. Governing Law\nThese Terms are governed by the laws of [State/Jurisdiction], without regard\nto conflict of law principles.\n","contact":{"email":"1source_help@equilend.com"},"license":{"name":"The MIT License (MIT)","url":"https://mit-license.org/"},"version":"1.3.0"},"servers":[{"url":"https://stageapi.equilend.com/v1","description":"Staging API Server"},{"url":"https://virtserver.swaggerhub.com/1SOURCE/1SOURCE-LEDGER-API/1.3.0","description":"SwaggerHub API Auto Mocking"}],"tags":[{"name":"parties","description":"Read the set of registered trading parties"},{"name":"delegations","description":"Set of parties with delegated authorities"},{"name":"events","description":"Read loan events"},{"name":"agreements","description":"Execution venue trade agreements either on or off platform"},{"name":"loans","description":"Manage loans on the ledger.\n\n### Loan lifecycle\n\nHappy path: `PROPOSED` → `PENDING` → `OPEN` → `CLOSED`\n\n| From | Operation | To | Event |\n|------|-----------|-----|-------|\n| — | `POST /ledger/loans` | `PROPOSED` | `LOAN_PROPOSED` |\n| `PROPOSED` | `POST /ledger/loans/{loanId}/approve` | `PENDING` | `LOAN_PENDING` |\n| `PROPOSED` | `POST /ledger/loans/{loanId}/cancel` | `CANCELED` | `LOAN_CANCELED` |\n| `PROPOSED` | `POST /ledger/loans/{loanId}/decline` | `DECLINED` | `LOAN_DECLINED` |\n| `PENDING` | `PATCH /ledger/loans/{loanId}` (`settlementStatus: SETTLED` by both parties) | `OPEN` | `LOAN_OPENED` |\n| `PENDING` | `POST /ledger/loans/{loanId}/cancelpending` | `CANCEL_PENDING` → `CANCELED` | `LOAN_CANCEL_PENDING` |\n| `OPEN` | `POST /ledger/loans/{loanId}/unwind` | `UNWIND_PENDING` | `LOAN_UNWIND_PENDING` |\n| `UNWIND_PENDING` | `POST /ledger/loans/{loanId}/unwind/approve` | `CLOSED` | `LOAN_CLOSED` |\n| `UNWIND_PENDING` | `POST /ledger/loans/{loanId}/unwind/decline` | `OPEN` | `LOAN_UNWIND_DECLINED` |\n| `UNWIND_PENDING` | `POST /ledger/loans/{loanId}/unwind/cancel` | `OPEN` | `LOAN_UNWIND_CANCELED` |\n\nApproval moves a loan to `PENDING` (pending settlement). A loan becomes `OPEN` only after both\ncounterparties mark settlement `SETTLED`.\n"},{"name":"rerates","description":"Propose, approve, decline a loan rerate"},{"name":"returns","description":"Initiate and manage a return on a loan"},{"name":"recalls","description":"Initiate and manage a recall on a loan"},{"name":"buyins","description":"Initiate and manage a buyin on a loan"}],"paths":{"/ledger/parties":{"get":{"tags":["parties"],"summary":"Read a collection of registered trading parties.","parameters":[{"name":"partyId","in":"query","description":"The ledger Party ID sometimes referred to as Short Code","required":false,"schema":{"$ref":"#/components/schemas/PartyId"}},{"name":"partyName","in":"query","description":"Party name as defined during onboarding","required":false,"schema":{"type":"string"}},{"name":"gleifLei","in":"query","description":"Global Legal Entity Identifier Foundation - Legal Entity Identifier","required":false,"schema":{"type":"string"}},{"name":"internalPartyId","in":"query","description":"Client internal or proprietary id for this party","required":false,"schema":{"type":"string"}},{"name":"partyType","in":"query","description":"Party Type from the PartyType schema","required":false,"schema":{"$ref":"#/components/schemas/PartyType"}}],"responses":{"200":{"description":"List of Parties","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Parties"}}}},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":["read_access"]}]}},"/ledger/delegations":{"get":{"tags":["delegations"],"summary":"Read a collection of delegations.","parameters":[{"name":"size","in":"query","description":"Number of delegation contracts to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"delegationStatus","in":"query","description":"Delegations with status matching DELEGATION STATUS","required":false,"schema":{"$ref":"#/components/schemas/DelegationStatus"}},{"name":"authorization","in":"query","description":"Delegations with authorization type matching AUTHORIZATION","required":false,"schema":{"$ref":"#/components/schemas/DelegationAuthorizationType"}}],"responses":{"200":{"description":"List of Delegations","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Delegations"}}}},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["delegations"],"summary":"Delegate a set of workflows to a party","requestBody":{"$ref":"#/components/requestBodies/DelegationProposal"},"responses":{"201":{"$ref":"#/components/responses/Success"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/delegations/{delegationId}":{"get":{"tags":["delegations"],"summary":"Read a party delegation","parameters":[{"name":"delegationId","in":"path","description":"The unique identifier of a party delegation","required":true,"schema":{"$ref":"#/components/schemas/DelegationId"}}],"responses":{"200":{"description":"The party delegation corresponding to the provided \"delegationId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Delegation"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/delegations/{delegationId}/approve":{"post":{"tags":["delegations"],"summary":"Approve a party delegation in \"proposed\" state","parameters":[{"name":"delegationId","in":"path","description":"The unique identifier of a party delegation","required":true,"schema":{"$ref":"#/components/schemas/DelegationId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/delegations/{delegationId}/cancel":{"post":{"tags":["delegations"],"summary":"Cancel a party delegation in \"proposed\" state. Original proposer only.","parameters":[{"name":"delegationId","in":"path","description":"The unique identifier of a party delegation","required":true,"schema":{"$ref":"#/components/schemas/DelegationId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/delegations/{delegationId}/decline":{"post":{"tags":["delegations"],"summary":"Decline a party delegation in \"proposed\" state","parameters":[{"name":"delegationId","in":"path","description":"The unique identifier of a party delegation","required":true,"schema":{"$ref":"#/components/schemas/DelegationId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/delegations/{delegationId}/remove":{"post":{"tags":["delegations"],"summary":"Propose removal of a party delegation in \"approved\" state","parameters":[{"name":"delegationId","in":"path","description":"The unique identifier of a party delegation","required":true,"schema":{"$ref":"#/components/schemas/DelegationId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/agreements":{"get":{"tags":["agreements"],"summary":"Read a collection of trade agreements. Defaults to return the last 100 trade agreeements created.","parameters":[{"name":"since","in":"query","description":"Agreements updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Agreements updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of agreements to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"List of trade agreements","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Agreements"}}}},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["agreements"],"summary":"Create a trade agreement","requestBody":{"$ref":"#/components/requestBodies/TradeAgreement"},"responses":{"201":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/agreements/{agreementId}":{"get":{"tags":["agreements"],"summary":"Read an agreement","parameters":[{"name":"agreementId","in":"path","description":"The unique identifier of a trade agreement","required":true,"schema":{"$ref":"#/components/schemas/AgreementId"}}],"responses":{"200":{"description":"The trade agreement corresponding to the provided \"agreementId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Agreement"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/venue/agreements":{"post":{"tags":["agreements"],"summary":"For delegated venues to create a trade agreement atomically","requestBody":{"$ref":"#/components/requestBodies/TradeAgreement"},"responses":{"201":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans":{"get":{"tags":["loans"],"summary":"Read a collection of loans. Defaults to return the last 100 loans updated.","parameters":[{"name":"since","in":"query","description":"Loans updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Loans updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of loans to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"loanStatus","in":"query","description":"Loans with status matching LOAN STATUS","required":false,"schema":{"$ref":"#/components/schemas/LoanStatus"}}],"responses":{"200":{"description":"List of loans","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Loans"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["loans"],"summary":"Create a loan in \"proposal\" state. Normally done by the Lend side","requestBody":{"$ref":"#/components/requestBodies/LoanProposal"},"responses":{"201":{"$ref":"#/components/responses/Created"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}":{"get":{"tags":["loans"],"summary":"Read a specific loan the user is authorized to access","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"description":"The loan corresponding to the provided \"loanId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Loan"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"patch":{"tags":["loans"],"summary":"Update unilateral fields in a loan","description":"Update internal reference, venue reference, settlement instructions, or settlement status.\n\nWhen both counterparties `PATCH` `settlementStatus` to `SETTLED` on a `PENDING` loan, the loan\ntransitions to `OPEN` and emits `LOAN_OPENED`.\n","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/loans_loanId_body"}}}},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/amend":{"post":{"tags":["loans"],"summary":"Amend a loan in \"open\" state. Allows a party to propose a change to an existing loan. All fields are optional but at least 1 must be provided. Any field provided must differ from the existing value on the loan","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanAmendmentProposal"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/amend/{loanAmendmentId}":{"get":{"tags":["loans"],"summary":"Retrieve a loan amendment.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"loanAmendmentId","in":"path","description":"The unique identifier of a loan amendment","required":true,"schema":{"$ref":"#/components/schemas/LoanAmendmentId"}}],"responses":{"200":{"description":"The loan amendment corresponding to the provided \"loanAmendmentId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanAmendment"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/amend/{loanAmendmentId}/approve":{"post":{"tags":["loans"],"summary":"Approve a loan amendment in \"proposed\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"loanAmendmentId","in":"path","description":"The unique identifier of a loan amendment","required":true,"schema":{"$ref":"#/components/schemas/LoanAmendmentId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/amend/{loanAmendmentId}/cancel":{"post":{"tags":["loans"],"summary":"Cancel a loan amendment in \"proposed\" state","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"loanAmendmentId","in":"path","description":"The unique identifier of a loan amendment","required":true,"schema":{"$ref":"#/components/schemas/LoanAmendmentId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanAmendmentProposalCancel"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/amend/{loanAmendmentId}/decline":{"post":{"tags":["loans"],"summary":"Decline a loan amendment in \"proposed\" state","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"loanAmendmentId","in":"path","description":"The unique identifier of a loan amendment","required":true,"schema":{"$ref":"#/components/schemas/LoanAmendmentId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanAmendmentProposalDecline"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/approve":{"post":{"tags":["loans"],"summary":"Approve a loan in \"proposed\" state. Borrowers should not send roundingRule, roundingMode, or minimumMarkPrice when approving a loan.","description":"Transitions `loanStatus` from `PROPOSED` to `PENDING`.\nEmits `LOAN_PENDING`. Does not open the loan; settlement must complete before `OPEN`.\n","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanProposalApproval"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/cancel":{"post":{"tags":["loans"],"summary":"Cancel a loan in \"proposed\" state. Original proposer only.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanProposalCancel"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/cancelpending":{"post":{"tags":["loans"],"summary":"Cancel a loan in \"pending\" state. Either party can initiate.","description":"Initiates cancellation of a `PENDING` loan before settlement.\nTransitions to `CANCEL_PENDING`; both parties must submit before `CANCELED`.\nEmits `LOAN_CANCEL_PENDING`.\n","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/decline":{"post":{"tags":["loans"],"summary":"Decline a loan in \"proposed\" state","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanProposalDecline"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/history":{"get":{"tags":["loans"],"summary":"Return an ordered history of this loan. Each loan has a reference event that triggered a new version.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"since","in":"query","description":"Events (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Events (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of loan changes to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"eventType","in":"query","description":"Filter by event type","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/EventType"}}},{"name":"eventId","in":"query","required":false,"schema":{"type":"integer","format":"int64"}},{"name":"sortOrder","in":"query","description":"Sort history by order of creation ascending or descending. Defaults to DESCENDING","required":false,"schema":{"$ref":"#/components/schemas/SortOrder"}}],"responses":{"200":{"description":"List of loans","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Loans"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/ratehistory":{"get":{"tags":["loans"],"summary":"Return an ordered history of effective rate changes.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"since","in":"query","description":"Events (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Events (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of effective rates to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}}],"responses":{"200":{"description":"List of effective rate changes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Rates"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/split":{"post":{"tags":["loans"],"summary":"Split an open loan into multiple lots","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanSplitProposal"},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/split/{loanSplitId}":{"get":{"tags":["loans"],"summary":"Retrieve a loan split.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"loanSplitId","in":"path","description":"The unique identifier of a loan split","required":true,"schema":{"$ref":"#/components/schemas/LoanSplitId"}}],"responses":{"200":{"description":"The loan split corresponding to the provided \"loanSplitId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanSplit"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/split/{loanSplitId}/acknowledge":{"post":{"tags":["loans"],"summary":"Acknowledge a loan split in \"proposed\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"loanSplitId","in":"path","description":"The unique identifier of a proposed loan split","required":true,"schema":{"$ref":"#/components/schemas/LoanSplitId"}}],"requestBody":{"$ref":"#/components/requestBodies/LoanSplitAcknowledgment"},"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/unwind":{"post":{"tags":["loans"],"summary":"Unwind/Close a loan in \"open\" state. Either party can initiate.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/unwind/approve":{"post":{"tags":["loans"],"summary":"Approve the unwind of a loan in \"open\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/unwind/decline":{"post":{"tags":["loans"],"summary":"Decline the unwind of a loan in \"open\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/unwind/cancel":{"post":{"tags":["loans"],"summary":"Cancel the unwind of a loan in \"open\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/events":{"get":{"tags":["events"],"summary":"Read collection of events against a specific loan. With no parameters returns events since start of current day.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"eventType","in":"query","description":"Filter by event type","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/EventType"}}},{"name":"beforeEventId","in":"query","required":false,"schema":{"type":"integer","format":"int64"}},{"name":"fromEventId","in":"query","required":false,"schema":{"type":"integer","format":"int64"}},{"name":"since","in":"query","description":"Events (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Events (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of events to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"sortOrder","in":"query","description":"Sort events by order of creation ascending or descending. Defaults to ASCENDING","required":false,"schema":{"$ref":"#/components/schemas/SortOrder"}}],"responses":{"200":{"description":"List of events","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Events"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/events/{eventId}":{"get":{"tags":["events"],"summary":"Read an event","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"eventId","in":"path","description":"The unique identifier of an Event","required":true,"schema":{"$ref":"#/components/schemas/EventId"}}],"responses":{"200":{"description":"The event corresponding to the provided \"eventId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns":{"get":{"tags":["returns"],"summary":"Read collection of returns against loan specified by 'loanId'","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"since","in":"query","description":"Returns updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Returns updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of returns to fetch. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"returnStatus","in":"query","description":"Returns with status matching RETURN STATUS","required":false,"schema":{"$ref":"#/components/schemas/ReturnStatus"}},{"name":"sortOrder","in":"query","description":"Sort events by order of creation ascending or descending. Defaults to ASCENDING","required":false,"schema":{"$ref":"#/components/schemas/SortOrder"}},{"name":"sortField","in":"query","description":"Field to sort by. Defaults to LASTUPDATEDATE","required":false,"schema":{"$ref":"#/components/schemas/ReturnSortField"}}],"responses":{"200":{"description":"List of returns","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Returns"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["returns"],"summary":"Create a return","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/ReturnProposal"},"responses":{"201":{"description":"The return was created","headers":{"Location":{"$ref":"#/components/headers/ReturnId"}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}":{"get":{"tags":["returns"],"summary":"Read a return","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"description":"The return corresponding to the provided \"returnId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"patch":{"tags":["returns"],"summary":"Update unilateral fields on a return","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/returns_returnId_body"}}}},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}/acknowledge":{"post":{"tags":["returns"],"summary":"Acknowledge a pending return. No change to status.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"requestBody":{"$ref":"#/components/requestBodies/ReturnAcknowledgement"},"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}/cancel":{"post":{"tags":["returns"],"summary":"Cancel a return in \"proposed\" or \"pending\" state. Original proposer only.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}/unwind":{"post":{"tags":["returns"],"summary":"Unwind/close a return that settled on the current date. Either party can initiate.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}/unwind/approve":{"post":{"tags":["returns"],"summary":"Approve the unwind of a return in 'settled' state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}/unwind/decline":{"post":{"tags":["returns"],"summary":"Decline the unwind of a return in 'settled' state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/returns/{returnId}/unwind/cancel":{"post":{"tags":["returns"],"summary":"Cancel the unwind of a return in 'settled' state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/recalls":{"get":{"tags":["recalls"],"summary":"Read collection of recalls against loan specified by 'loanId'","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"since","in":"query","description":"Recalls updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Recalls updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of recalls to fetch. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"recallStatus","in":"query","description":"Recalls with status matching RECALL STATUS","required":false,"schema":{"$ref":"#/components/schemas/RecallStatus"}}],"responses":{"200":{"description":"List of recalls","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Recalls"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["recalls"],"summary":"Initiates a recall","description":"Initiates a recall notice to return securities on a loan. \n### Validation rules:\n  - Caller must be the lender on the loan\n  - `loanId` -- must reference an `OPEN` loan\n  - `executionVenue`\n    - is mandatory\n    - if `executionVenue.type` == `ONPLATFORM` then all other elements in `executionVenue` must be null\n    - if `executionVenue.type` == `OFFPLATFORM` then `executionVenue.partyId`, `executionVenue.venueName`, and `executionVenue.partyRole` are mandatory\n  - `quantity`\n    - is mandatory\n    - must be < 0\n    - must be <= loan open quantity - all existing open recall quantities\n  - `recallDate`\n    - is mandatory\n    - must be >= current day\n  - `recallDueDate`\n    - is mandatory\n    - must be > `recallDate`\n","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/RecallProposal"},"responses":{"201":{"description":"The recall was created","headers":{"Location":{"$ref":"#/components/headers/RecallId"}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/recalls/{recallId}":{"get":{"tags":["recalls"],"summary":"Read a recall","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"recallId","in":"path","description":"The unique identifier of a recall","required":true,"schema":{"$ref":"#/components/schemas/RecallId"}}],"responses":{"200":{"description":"The recall corresponding to the provided \"recallId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Recall"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"patch":{"tags":["recalls"],"summary":"Update unilateral fields on a recall","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"recallId","in":"path","description":"The unique identifier of a recall","required":true,"schema":{"$ref":"#/components/schemas/RecallId"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/recalls_recallId_body"}}}},"responses":{"200":{"$ref":"#/components/responses/Success"},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/recalls/{recallId}/cancel":{"post":{"tags":["recalls"],"summary":"Cancel a recall in \"proposed\" state. Original proposer only.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"recallId","in":"path","description":"The unique identifier of a recall","required":true,"schema":{"$ref":"#/components/schemas/RecallId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/recalls/{recallId}/acknowledge":{"post":{"tags":["recalls"],"summary":"Acknowledge a pending recall. No change to status.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"recallId","in":"path","description":"The unique identifier of a recall","required":true,"schema":{"$ref":"#/components/schemas/RecallId"}}],"requestBody":{"$ref":"#/components/requestBodies/RecallAcknowledgement"},"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/rerates":{"get":{"tags":["rerates"],"summary":"Read collection of rerates against loan specified by 'loanId'","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"since","in":"query","description":"Rerates updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Rerates updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of rerates to fetch. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"rerateStatus","in":"query","description":"Rerates with status matching RERATE STATUS","required":false,"schema":{"$ref":"#/components/schemas/RerateStatus"}}],"responses":{"200":{"description":"List of rerates","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Rerates"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["rerates"],"summary":"Create a rerate.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"$ref":"#/components/requestBodies/RerateProposal"},"responses":{"201":{"description":"The rerate was created","headers":{"Location":{"$ref":"#/components/headers/RerateId"}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/rerates/{rerateId}":{"get":{"tags":["rerates"],"summary":"Read a rerate","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"rerateId","in":"path","description":"The unique identifier of a rerate","required":true,"schema":{"$ref":"#/components/schemas/RerateId"}}],"responses":{"200":{"description":"The rerate corresponding to the provided \"rerateId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Rerate"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/rerates/{rerateId}/approve":{"post":{"tags":["rerates"],"summary":"Approve a rerate in \"proposed\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"rerateId","in":"path","description":"The unique identifier of a rerate","required":true,"schema":{"$ref":"#/components/schemas/RerateId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/rerates/{rerateId}/cancel":{"post":{"tags":["rerates"],"summary":"Cancel a rerate in \"proposed\" state. Original proposer only.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"rerateId","in":"path","description":"The unique identifier of a rerate","required":true,"schema":{"$ref":"#/components/schemas/RerateId"}}],"requestBody":{"$ref":"#/components/requestBodies/RerateProposalCancel"},"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/rerates/{rerateId}/cancelpending":{"post":{"tags":["rerates"],"summary":"Cancel a rerate in \"pending\" state. Either party can initiate. If canceled by a delegated Venue, the cancel will be done unilaterally","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"rerateId","in":"path","description":"The unique identifier of a rerate","required":true,"schema":{"$ref":"#/components/schemas/RerateId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/rerates/{rerateId}/decline":{"post":{"tags":["rerates"],"summary":"Decline a rerate in \"proposed\" state.","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"rerateId","in":"path","description":"The unique identifier of a rerate","required":true,"schema":{"$ref":"#/components/schemas/RerateId"}}],"requestBody":{"$ref":"#/components/requestBodies/RerateProposalDecline"},"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/buyins/completes":{"get":{"tags":["buyins"],"summary":"Read collection of completed buyins against loan specified by 'loanId'","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"responses":{"200":{"description":"List of completed buyins","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyinCompletes"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]},"post":{"tags":["buyins"],"summary":"Complete a buyin","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyinCompleteRequest"}}}},"responses":{"201":{"description":"The buyin was completed","headers":{"Location":{"$ref":"#/components/headers/BuyinCompleteId"}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/buyins/completes/{buyinCompleteId}":{"get":{"tags":["buyins"],"summary":"Read a completed Buyin","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"buyinCompleteId","in":"path","description":"The unique identifier of a completed buyin","required":true,"schema":{"$ref":"#/components/schemas/BuyinCompleteId"}}],"responses":{"200":{"description":"The completed buyin corresponding to the provided \"buyinCompleteId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyinComplete"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/loans/{loanId}/buyins/completes/{buyinCompleteId}/accept":{"post":{"tags":["buyins"],"summary":"Complete some or all of an initiated Buyin","parameters":[{"name":"loanId","in":"path","description":"The unique identifier of a loan","required":true,"schema":{"$ref":"#/components/schemas/LoanId"}},{"name":"buyinCompleteId","in":"path","description":"The unique identifier of a completed buyin","required":true,"schema":{"$ref":"#/components/schemas/BuyinCompleteId"}}],"responses":{"200":{"$ref":"#/components/responses/Success"},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/events":{"get":{"tags":["events"],"summary":"Read collection of events. With no parameters returns events since start of current day.","parameters":[{"name":"eventType","in":"query","description":"Filter by event type","required":false,"schema":{"type":"array","items":{"$ref":"#/components/schemas/EventType"}}},{"name":"beforeEventId","in":"query","required":false,"schema":{"type":"integer","format":"int64"}},{"name":"fromEventId","in":"query","required":false,"schema":{"type":"integer","format":"int64"}},{"name":"since","in":"query","description":"Events (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Events (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of events to be returned. Can be used to facilitate paging. Defaults to 100","required":false,"schema":{"type":"integer"}},{"name":"sortOrder","in":"query","description":"Sort events by order of creation ascending or descending. Defaults to ASCENDING","required":false,"schema":{"$ref":"#/components/schemas/SortOrder"}}],"responses":{"200":{"description":"List of events","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Events"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/events/{eventId}":{"get":{"tags":["events"],"summary":"Read an event","parameters":[{"name":"eventId","in":"path","description":"The unique identifier of an event","required":true,"schema":{"$ref":"#/components/schemas/EventId"}}],"responses":{"200":{"description":"The event corresponding to the provided \"eventId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/returns":{"get":{"tags":["returns"],"summary":"Read collection of returns","parameters":[{"name":"since","in":"query","description":"Returns updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Returns updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of returns to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"returnStatus","in":"query","description":"Returns matching status RETURN STATUS","required":false,"schema":{"$ref":"#/components/schemas/ReturnStatus"}},{"name":"sortOrder","in":"query","description":"Sort events by order of creation ascending or descending. Defaults to ASCENDING","required":false,"schema":{"$ref":"#/components/schemas/SortOrder"}},{"name":"sortField","in":"query","description":"Field to sort by. Defaults to LASTUPDATEDATE","required":false,"schema":{"$ref":"#/components/schemas/ReturnSortField"}}],"responses":{"200":{"description":"List of returns","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Returns"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/returns/{returnId}":{"get":{"tags":["returns"],"summary":"Read a return","parameters":[{"name":"returnId","in":"path","description":"The unique identifier of a return","required":true,"schema":{"$ref":"#/components/schemas/ReturnId"}}],"responses":{"200":{"description":"The return corresponding to the provided \"returnId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Return"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/recalls":{"get":{"tags":["recalls"],"summary":"Read collection of recalls","parameters":[{"name":"since","in":"query","description":"Recalls updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Recalls updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of recalls to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"recallStatus","in":"query","description":"Recalls matching status RECALL STATUS","required":false,"schema":{"$ref":"#/components/schemas/RecallStatus"}}],"responses":{"200":{"description":"List of recalls","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Recalls"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/recalls/{recallId}":{"get":{"tags":["recalls"],"summary":"Read a recall","parameters":[{"name":"recallId","in":"path","description":"The unique identifier of a recall","required":true,"schema":{"$ref":"#/components/schemas/RecallId"}}],"responses":{"200":{"description":"The recall corresponding to the provided \"recallId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Recall"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/rerates":{"get":{"tags":["rerates"],"summary":"Read collection of rerates","parameters":[{"name":"since","in":"query","description":"Rerates updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Rerates updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of rerates to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"rerateStatus","in":"query","description":"Loans matching status RERATE STATUS","required":false,"schema":{"$ref":"#/components/schemas/RerateStatus"}}],"responses":{"200":{"description":"List of rerates","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Rerates"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/rerates/{rerateId}":{"get":{"tags":["rerates"],"summary":"Read a rerate","parameters":[{"name":"rerateId","in":"path","description":"The unique identifier of a rerate","required":true,"schema":{"$ref":"#/components/schemas/RerateId"}}],"responses":{"200":{"description":"The rerate corresponding to the provided \"rerateId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Rerate"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/buyins/completes":{"get":{"tags":["buyins"],"summary":"Read collection of completed buyins","parameters":[{"name":"since","in":"query","description":"Completed buyins updated (since) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"before","in":"query","description":"Completed buyins updated (before) timestamp UTC","required":false,"schema":{"$ref":"#/components/schemas/DateTimeType"}},{"name":"size","in":"query","description":"Number of completed buyins to be returned. Can be used to facilitate paging","required":false,"schema":{"type":"integer"}},{"name":"buyinCompleteStatus","in":"query","description":"Completed buyins matching status BUYIN COMPLETE STATUS","required":false,"schema":{"$ref":"#/components/schemas/BuyinCompleteStatus"}}],"responses":{"200":{"description":"List of completed buyins","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyinCompletes"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}},"/ledger/buyins/completes/{buyinCompleteId}":{"get":{"tags":["buyins"],"summary":"Read a completed buyin","parameters":[{"name":"buyinCompleteId","in":"path","description":"The unique identifier of a completed buyin","required":true,"schema":{"$ref":"#/components/schemas/BuyinCompleteId"}}],"responses":{"200":{"description":"The completed buyin corresponding to the provided \"buyinCompleteId\"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BuyinComplete"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"404":{"$ref":"#/components/responses/NotFound"},"500":{"$ref":"#/components/responses/Error"}},"security":[{"stage_auth":[]}]}}},"components":{"schemas":{"AcknowledgementType":{"type":"string","enum":["NEGATIVE","POSITIVE"]},"AgreementId":{"type":"string","description":"The unique identifier of a trade agreement - UUID"},"Agreement":{"required":["agreementId","status"],"type":"object","properties":{"agreementId":{"$ref":"#/components/schemas/AgreementId"},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"},"trade":{"$ref":"#/components/schemas/VenueTradeAgreement"}}},"Agreements":{"type":"array","items":{"$ref":"#/components/schemas/Agreement"}},"BenchmarkCd":{"type":"string","enum":["EFFR","OBFR","SOFR","CORRA"]},"BuyinComplete":{"required":["buyinCompleteId","lastUpdateDateTime","loanId","quantity","status"],"type":"object","properties":{"buyinCompleteId":{"$ref":"#/components/schemas/BuyinCompleteId"},"loanId":{"$ref":"#/components/schemas/LoanId"},"status":{"$ref":"#/components/schemas/BuyinCompleteStatus"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"buyinDate":{"$ref":"#/components/schemas/DateType"},"price":{"$ref":"#/components/schemas/Price"},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"},"createDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"BuyinCompleteId":{"type":"string","description":"The unique identifier of an initiated buyin - UUID"},"BuyinCompleteRequest":{"required":["quantity"],"type":"object","properties":{"quantity":{"$ref":"#/components/schemas/IntegerType"},"buyinDate":{"$ref":"#/components/schemas/DateType"},"price":{"$ref":"#/components/schemas/Price"}}},"BuyinCompletes":{"type":"array","items":{"$ref":"#/components/schemas/BuyinComplete"}},"BuyinCompleteStatus":{"type":"string","enum":["PENDING","COMPLETE"]},"CcpIndicator":{"type":"string","enum":["OCC_HEDGE"]},"CdsCustomerUnitId":{"type":"string","description":"CDS Customer Unit Identifier (of the local agent)"},"Collateral":{"required":["collateralCurrency","collateralMargin","collateralType","collateralValue","contractPrice"],"type":"object","properties":{"contractPrice":{"$ref":"#/components/schemas/DoubleType"},"contractValue":{"$ref":"#/components/schemas/DoubleType"},"collateralValue":{"$ref":"#/components/schemas/DoubleType"},"collateralCurrency":{"$ref":"#/components/schemas/CurrencyCd"},"collateralType":{"$ref":"#/components/schemas/CollateralType"},"collateralDescriptionCode":{"$ref":"#/components/schemas/CollateralDescription"},"collateralMargin":{"$ref":"#/components/schemas/DoubleType"},"roundingRule":{"$ref":"#/components/schemas/IntegerType"},"roundingMode":{"$ref":"#/components/schemas/RoundingMode"},"minimumMarkPrice":{"$ref":"#/components/schemas/DoubleType"},"mark":{"$ref":"#/components/schemas/MarkDelta"},"prepay":{"$ref":"#/components/schemas/Prepay"},"custodian":{"$ref":"#/components/schemas/Custodian"}},"description":"Rounding rule, rounding mode are required when the Lender is proposing or approving a loan. For non-OCC loans, minimum mark price is also required"},"CollateralAmendment":{"type":"object","properties":{"collateralCurrency":{"$ref":"#/components/schemas/CurrencyCd"},"collateralMargin":{"$ref":"#/components/schemas/DoubleType"},"roundingRule":{"$ref":"#/components/schemas/IntegerType"},"roundingMode":{"$ref":"#/components/schemas/RoundingMode"},"minimumMarkPrice":{"$ref":"#/components/schemas/DoubleType"}}},"CollateralDescription":{"type":"string","enum":["NONUSAGENCIES","AGENCIES","CANADIANBONDS","CANADIANPROVINCIALS","CORPORATES","DEBT","EMUDEBTAAA","EMUDEBT","AUSTRALIANEQUITIES","EQUITIES","GOVTDEBT105","G10DEBT","G3DEBT","G8DEBT","UKGILTS","GOVERNMENTISSUES","GOVERNMENTISSUESAAA","HIGHGRADEEQUITIES","INVESTMENTGRADECORPORATES","JAPANESEGOVERNMENTBONDS"]},"CollateralType":{"type":"string","enum":["CASH","NONCASH","CASHPOOL"]},"CurrencyCd":{"type":"string","enum":["USD","EUR","GBP","JPY","AUD","HKD","CAD","CHF","SEK","SGD","NOK","DKK"]},"Custodian":{"type":"object","properties":{"custodianType":{"$ref":"#/components/schemas/CustodianType"},"custodianName":{"type":"string","description":"Custodian Bank Name"},"custodianBic":{"type":"string","description":"Custodian Bank BIC"},"custodianAccount":{"type":"string","description":"Custodian Bank Account"}}},"CustodianType":{"type":"string","enum":["BILATERAL","TRIPARTY"]},"DateType":{"type":"string","description":"YYYY-MM-DD","format":"date"},"DateTimeType":{"type":"string","description":"YYYY-MM-DDTHH:MI:SS.XXXZ","format":"date-time"},"Delegation":{"required":["authorizations","counterPartyId","partyId","venuePartyId"],"type":"object","properties":{"delegationId":{"$ref":"#/components/schemas/DelegationId"},"delegationStatus":{"$ref":"#/components/schemas/DelegationStatus"},"delegationParty":{"$ref":"#/components/schemas/Party"},"parties":{"type":"array","items":{"$ref":"#/components/schemas/Party"}},"authorization":{"$ref":"#/components/schemas/DelegationAuthorizationType"},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"DelegationAuthorization":{"required":["authorizationType"],"type":"object","properties":{"authorizationType":{"$ref":"#/components/schemas/DelegationAuthorizationType"}}},"DelegationAuthorizationType":{"type":"string","enum":["LOANS","RETURNS","RECALLS","RERATES","BUYINS"]},"DelegationId":{"type":"string","description":"The unique identifier of a party delegation"},"DelegationProposal":{"required":["authorizations","counterparty","delegationParty"],"type":"object","properties":{"delegationParty":{"$ref":"#/components/schemas/Party"},"counterparty":{"$ref":"#/components/schemas/Party"},"authorization":{"$ref":"#/components/schemas/DelegationAuthorization"}}},"Delegations":{"type":"array","items":{"$ref":"#/components/schemas/Delegation"}},"DelegationStatus":{"type":"string","enum":["PROPOSED","APPROVED","CANCELED","DECLINED","REMOVED"]},"DoubleType":{"type":"number","format":"double"},"DtcPartipantNumber":{"type":"string","description":"DTC Participant Number (of the Local Agent)"},"EventType":{"type":"string","description":"Event Types:\n * `AUTO_RERATE_APPLIED` - A loan with a floating rebate tied to a benchmark has been updated after a benchmark move. `rate.rebate.floating.[baseRate,effectiveRate]` have been recalculated.\n * `BUYIN_COMPLETED` - `buyin.buyinCompleteId` has been accepted by the counterparty. The status is now `COMPLETED`. `loan.trade.openQuantity` was updated to reflect the buy-in.\n * `BUYIN_PENDING` - The lending party has bought-in the counterparty on `loan.loanId` for `buyin.quantity` at `buyin.price`.\n * `DELEGATION_APPROVED` - `delegation.delegationId` was approved by the proposing party. The status is now `APPROVED`.\n * `DELEGATION_CANCELED` - `delegation.delegationId` was canceled by the proposing party. The status is now `CANCELED`.\n * `DELEGATION_PROPOSED` - A party is proposing to counterparty `delegation.counterparty` that `delegation.authorization` be granted to `delegation.delegationParty`. This allows `delegation.delegationParty` to exercise life cycle events on behalf of the counterparties.\n * `DELEGATION_DECLINED` - `delegation.delegationId` was declined by the counterparty. The status is now `DECLINED`. \n * `INTERNAL_REFID_UPDATE` - `loan.trade.transactingParties[].internalReference` was updated by one of the parties.\n * `LOAN_PROPOSED` - A new loan was proposed on the ledger identified as `loanId`.\n * `LOAN_PENDING` - `loan.loanId` was approved by the counterparty and is now `PENDING`.\n * `LOAN_CANCELED` - `loan.loanId` was canceled by the proposing party. `loan.loanStatusReason` has more information.\n * `LOAN_CANCEL_PENDING` - A `PENDING` loan is requested to be canceled before being settled. Both parties must submit the request. The initiator can provide `loan.loanStatusReason`.\n * `LOAN_CLOSED` - An `OPEN` loan has been fully returned. `loan.trade.openQuantity` is 0. `loan.loanStatus` is now `CLOSED`.\n * `LOAN_DECLINED` - A loan proposal was declined by the counterparty. `loan.loanStatusReason` has more information.\n * `LOAN_MARKTOMARKET` - An `OPEN` loan was marked-to-market. The `loan.trade.instrument.price.value` was updated. `loan.trade.collateral.[contractPrice, contractValue, collateralValue]` were updated based on the new price.\n * `LOAN_OPENED` - A loan was marked as `SETTLED` by both counterparties and now has status `OPEN`.\n * `LOAN_UNWIND_PENDING` - An `OPEN` loan unwind was proposed by a counterparty. `loan.loanStatus` is now `UNWIND_PENDING`.\n * `LOAN_UNWIND_DECLINED` - A proposed loan unwind was declined. `loan.loanStatus` returns to `OPEN`.\n * `LOAN_UNWIND_CANCELED` - A proposed loan unwind was canceled. `loan.loanStatus` returns to `OPEN`.\n * `LOAN_SPLIT_PROPOSED` - A party to `OPEN` loan `loan.loanId` has proposed to split the loan. The loan split is identified as `loanSplitId`.\n * `LOAN_SPLIT_APPLIED` - A proposed split of `loan.loanId` was applied. `LOAN_OPENED` events will publish for the fractional loans.\n * `RECALL_ACKNOWLEDGED` - An `OPEN` recall on `recall.loanId` has been positively or negatively acknowledged by the counterparty. `recall.acknowledgementType` has been updated to `POSITIVE` or `NEGATIVE` and `recall.description` has more information on the reason.\n * `RECALL_CANCELED` - An `OPEN` recall was canceled by the opening party. `recall.status` is now `CANCELED`.\n * `RECALL_CLOSED` - An `OPEN` recall was closed after being fully satisifed by a return. `recall.status` is now `CLOSED`.\n * `RECALL_MODIFIED` - The `recall.quantity` was updated on an `OPEN` recall against `recall.loanId`.\n * `RECALL_OPENED` - A recall was opened against `recall.loanId` for `recall.quantity`. `recall.status` is `OPEN`.\n * `RECALL_UPDATED` - The `recall.openQuantity` was changed after a settled return was applied to `recall.loanId`.\n * `RERATE_APPLIED` - A `PENDING` rerate against `rerate.loanId` was applied. `loan.trade.rate` was updated.\n * `RERATE_CANCELED` - A `PROPOSED` rerate was canceled by the proposing party.\n * `RERATE_CANCEL_PENDING` - A `PENDING` rerate is requested to be canceled before being applied. Both parties must submit the request. The initiator can provide `rerate.statusReason`.\n * `RERATE_DECLINED` - The counterparty has declined a rerate proposal. Reason found in `rerate.statusReason`.\n * `RERATE_PENDING` - A `PROPOSED` rerate has been approved by the counterparty. It will be applied based on `rerate.rerate.{rate}.effectiveDate`.\n * `RERATE_PROPOSED` - A rerate has been proposed against `rerate.loanId`. Existing rate is `rerate.rate` and proposed rerate is `rerate.rerate`.\n * `RETURN_ACKNOWLEDGED` - A `PENDING` return on `return.loanId` has been positively or negatively acknowledged by the counterparty. `return.acknowledgementType` has been updated to `POSITIVE` or `NEGATIVE` and `return.description` has more information on the reason.\n * `RETURN_CANCELED` - A `PENDING` return on `return.loanId` has been canceled. `return.status` is now `CANCELED`.\n * `RETURN_PENDING` - A return is `PENDING` on `return.loanId`\n * `RETURN_SETTLED` - A `PENDING` return has been settled. `return.status` is now `SETTLED`. The `loan.trade.openQuantity` of loan referenced by `return.loanId` has been updated.\n * `RETURN_SETTLEMENT_STATUS_UPDATE` - The settlement status of a return was updated by one of the transacting parties. `return.settlement[].settlementStatus`.\n * `SETTLEMENT_INSTRUCTION_UPDATE` - Settlement instructions on a loan were updated by one of the transacting parties. `loan.settlement[].instruction`.\n * `SETTLEMENT_STATUS_UPDATE` - The settlement status of a loan was updated by one of the transacting parties. `loan.settlement[].settlementStatus`.\n * `TRADE_AGREED` - A trade agreement was created by a delegated venue.\n * `VENUE_REFERENCE_UPDATE` - A delegated venue has updated `loan.trade.venues[].venueRefKey`.\n","enum":["AUTO_RERATE_APPLIED","BUYIN_COMPLETED","BUYIN_PENDING","DELEGATION_APPROVED","DELEGATION_CANCELED","DELEGATION_PROPOSED","DELEGATION_DECLINED","DELEGATION_REMOVAL_PENDING","DELEGATION_REMOVED","INTERNAL_REFID_UPDATE","LOAN_AMENDMENT_APPLIED","LOAN_AMENDMENT_CANCELED","LOAN_AMENDMENT_DECLINED","LOAN_AMENDMENT_PROPOSED","LOAN_PROPOSED","LOAN_PENDING","LOAN_CANCELED","LOAN_CANCEL_PENDING","LOAN_CLOSED","LOAN_UNWIND_PENDING","LOAN_UNWIND_CANCELED","LOAN_UNWIND_DECLINED","LOAN_DECLINED","LOAN_MARKTOMARKET","LOAN_OPENED","LOAN_SPLIT_PROPOSED","LOAN_SPLIT_APPLIED","RECALL_ACKNOWLEDGED","RECALL_CANCELED","RECALL_CLOSED","RECALL_INTERNAL_REFID_UPDATE","RECALL_MODIFIED","RECALL_OPENED","RECALL_UPDATED","RERATE_APPLIED","RERATE_CANCELED","RERATE_CANCEL_PENDING","RERATE_DECLINED","RERATE_PENDING","RERATE_PROPOSED","RERATE_DELETED","RETURN_ACKNOWLEDGED","RETURN_CANCELED","RETURN_INTERNAL_REFID_UPDATE","RETURN_PENDING","RETURN_SETTLED","RETURN_SETTLEMENT_STATUS_UPDATE","RETURN_UNWIND_CANCELED","RETURN_UNWIND_DECLINED","RETURN_UNWIND_PENDING","SETTLEMENT_INSTRUCTION_UPDATE","SETTLEMENT_STATUS_UPDATE","TRADE_AGREED","TRADE_CANCELED","VENUE_REFERENCE_UPDATE"]},"EventId":{"type":"integer","description":"The unique identifier of an event - sequencial number","format":"int64"},"Event":{"required":["eventId","eventType"],"type":"object","properties":{"eventId":{"$ref":"#/components/schemas/EventId"},"eventType":{"$ref":"#/components/schemas/EventType"},"eventDateTime":{"$ref":"#/components/schemas/DateTimeType"},"resourceUri":{"type":"string"}}},"Events":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"FeeRate":{"type":"object","properties":{"fee":{"$ref":"#/components/schemas/FixedRateDef"}}},"FixedRate":{"type":"object","properties":{"fixed":{"$ref":"#/components/schemas/FixedRateDef"}}},"FixedRateDef":{"required":["baseRate","effectiveDate"],"type":"object","properties":{"baseRate":{"$ref":"#/components/schemas/DoubleType"},"effectiveRate":{"$ref":"#/components/schemas/DoubleType"},"effectiveDate":{"$ref":"#/components/schemas/DateType"},"rerateCutoffTime":{"pattern":"([01]?[0-9]|2[0-3]):[0-5][0-9]","type":"string","description":"Ignored on rerate proposals"}},"description":"Fixed Rates are defined as a base rate. When proposing a loan the base rate is required."},"FloatingRate":{"type":"object","properties":{"floating":{"$ref":"#/components/schemas/FloatingRateDef"}}},"FloatingRateDef":{"required":["benchmark","effectiveDate","spread"],"type":"object","properties":{"benchmark":{"$ref":"#/components/schemas/BenchmarkCd"},"baseRate":{"$ref":"#/components/schemas/DoubleType"},"spread":{"$ref":"#/components/schemas/DoubleType"},"effectiveRate":{"$ref":"#/components/schemas/DoubleType"},"isAutoRerate":{"type":"boolean"},"effectiveDate":{"$ref":"#/components/schemas/DateType"},"rerateCutoffTime":{"pattern":"([01]?[0-9]|2[0-3]):[0-5][0-9]","type":"string","description":"Ignored on rerate proposals"}},"description":"Floating Rates are defined as a spread off of a benchmark. When proposing a loan or rerate, the benchmark, spread, and effective date are required. Base rate is provided by 1Source if auto rerate is true, otherwise base rate is also required."},"Instrument":{"type":"object","properties":{"ticker":{"type":"string"},"cusip":{"type":"string"},"isin":{"type":"string"},"sedol":{"type":"string"},"quick":{"type":"string"},"figi":{"type":"string"},"marketCode":{"type":"string"},"description":{"type":"string"},"price":{"$ref":"#/components/schemas/Price"}},"description":"For loan proposals one of ticker, cusip, isin, sedol, quick, figi is required. If sending ticker, cusip, isin or quick, marketCode is required. Market code is the ISO country of exchange. All security identifiers are resolved to FIGI before creating a loan on ledger."},"IntegerType":{"type":"integer","format":"int32"},"InternalReference":{"type":"string","description":"A Transacting Party's internal system identifier"},"InternalReferenceUpdate":{"required":["internalReference"],"type":"object","properties":{"internalReference":{"type":"string"}}},"LedgerResponse":{"required":["message"],"type":"object","properties":{"code":{"type":"string"},"type":{"type":"string"},"responseDateTime":{"$ref":"#/components/schemas/DateTimeType"},"message":{"type":"string"},"resourceUri":{"type":"string"}}},"Loan":{"required":["lastUpdateDateTime","loanId","loanStatus"],"type":"object","properties":{"loanId":{"$ref":"#/components/schemas/LoanId"},"lastEvent":{"$ref":"#/components/schemas/Event"},"loanStatus":{"$ref":"#/components/schemas/LoanStatus"},"loanStatusReason":{"oneOf":[{"$ref":"#/components/schemas/LoanCancelErrorResponse"},{"$ref":"#/components/schemas/LoanDeclineErrorResponse"}]},"lastUpdatePartyId":{"$ref":"#/components/schemas/PartyId"},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"},"isInitiator":{"type":"boolean"},"trade":{"$ref":"#/components/schemas/TradeAgreement"},"settlement":{"type":"array","items":{"$ref":"#/components/schemas/PartySettlementInstruction"}},"parentLoanId":{"$ref":"#/components/schemas/LoanId"},"loanCorrelationId":{"$ref":"#/components/schemas/LoanCorrelationId"},"createDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"LoanAmendmentId":{"maxLength":36,"minLength":36,"type":"string","description":"The unique identifier of a loan amendment - UUID"},"LoanAmendment":{"required":["loanAmendmentId","trade"],"type":"object","properties":{"loanAmendmentId":{"$ref":"#/components/schemas/LoanAmendmentId"},"loanId":{"$ref":"#/components/schemas/LoanId"},"loanAmendmentStatus":{"$ref":"#/components/schemas/LoanAmendmentStatus"},"loanAmendmentStatusReason":{"oneOf":[{"$ref":"#/components/schemas/LoanCancelErrorResponse"},{"$ref":"#/components/schemas/LoanDeclineErrorResponse"}]},"trade":{"$ref":"#/components/schemas/TradeAmendment"},"settlement":{"type":"array","items":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}}}},"LoanAmendmentProposal":{"required":["trade"],"type":"object","properties":{"trade":{"$ref":"#/components/schemas/TradeAmendment"},"settlement":{"type":"array","items":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}}}},"LoanAmendmentStatus":{"type":"string","enum":["PROPOSED","CANCELED","DECLINED","CLOSED"]},"LoanCancelErrorReason":{"type":"string","enum":["NO_RESPONSE"]},"LoanCancelErrorResponse":{"required":["reason"],"type":"object","properties":{"reason":{"$ref":"#/components/schemas/LoanCancelErrorReason"}}},"LoanCorrelationId":{"maxLength":14,"minLength":14,"type":"string","description":"An additional loan identifier useful in legacy applications"},"LoanDeclineErrorReason":{"type":"string","enum":["INCORRECT_LOAN_INFO","UNKNOWN_LOAN","MISSING_INFORMATION"]},"LoanDeclineErrorReasonFieldBillingCurrency":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["BILLING_CURRENCY"]},"expectedValue":{"$ref":"#/components/schemas/CurrencyCd"}}},"LoanDeclineErrorReasonFieldCcpIndicator":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["CCP_INDICATOR"]},"expectedValue":{"$ref":"#/components/schemas/CcpIndicator"}}},"LoanDeclineErrorReasonFieldCollateralCurrency":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["COLLATERAL_CURRENCY"]},"expectedValue":{"$ref":"#/components/schemas/CurrencyCd"}}},"LoanDeclineErrorReasonFieldCollateralMargin":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["COLLATERAL_MARGIN"]},"expectedValue":{"$ref":"#/components/schemas/DoubleType"}}},"LoanDeclineErrorReasonFieldDividendRate":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["DIVIDEND_RATE"]},"expectedValue":{"$ref":"#/components/schemas/DoubleType"}}},"LoanDeclineErrorReasonFieldResetDate":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["RESET_DATE"]},"expectedValue":{"$ref":"#/components/schemas/DateType"}}},"LoanDeclineErrorReasonFieldSettlement":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["SETTLEMENT"]},"expectedValue":{"$ref":"#/components/schemas/PartySettlementInstruction"}}},"LoanDeclineErrorReasonFieldSettlementType":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["SETTLEMENT_TYPE"]},"expectedValue":{"$ref":"#/components/schemas/SettlementType"}}},"LoanDeclineErrorReasonFieldTermDate":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["TERM_DATE"]},"expectedValue":{"$ref":"#/components/schemas/DateType"}}},"LoanDeclineErrorReasonFieldTermType":{"required":["expectedValue","field"],"type":"object","properties":{"field":{"type":"string","enum":["TERM_TYPE"]},"expectedValue":{"$ref":"#/components/schemas/TermType"}}},"LoanDeclineErrorResponse":{"required":["reason"],"type":"object","properties":{"reason":{"$ref":"#/components/schemas/LoanDeclineErrorReason"},"errors":{"type":"array","items":{"anyOf":[{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldBillingCurrency"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldCcpIndicator"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldCollateralCurrency"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldCollateralMargin"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldDividendRate"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldResetDate"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldSettlement"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldSettlementType"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldTermDate"},{"$ref":"#/components/schemas/LoanDeclineErrorReasonFieldTermType"}]}}},"description":"Loan Decline Error Reason Field Types and Expected Values:\n * `BILLING_CURRENCY` - [CurrencyCd](1.3.0#/schemas/CurrencyCd) enum.\n * `CCP_INDICATOR` - [CcpIndicator](1.3.0#/schemas/CcpIndicator) enum.\n * `COLLATERAL_CURRENCY` - [CurrencyCd](1.3.0#/schemas/CurrencyCd) enum.\n * `COLLATERAL_MARGIN` - [DoubleType](1.3.0#/schemas/DoubleType) enum.\n * `DIVIDEND_RATE` - [DoubleType](1.3.0#/schemas/DoubleType) number.\n * `RESET_DATE` - [DateType](1.3.0#/schemas/DateType) string.\n * `SETTLEMENT` - [PartySettlementInstruction](1.3.0#/schemas/PartySettlementInstruction) object.\n * `SETTLEMENT_TYPE` - [SettlementType](1.3.0#/schemas/SettlementType) enum.\n * `TERM_DATE` - [DateType](1.3.0#/schemas/DateType) string.\n * `TERM_TYPE` - [TermType](1.3.0#/schemas/TermType) enum.\n"},"LoanId":{"maxLength":36,"minLength":36,"type":"string","description":"The unique identifier of a loan - UUID"},"LoanProposal":{"required":["settlement","trade"],"type":"object","properties":{"trade":{"$ref":"#/components/schemas/TradeAgreement"},"settlement":{"type":"array","items":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}}}},"LoanProposalApproval":{"required":["internalReference"],"type":"object","properties":{"internalReference":{"$ref":"#/components/schemas/InternalReference"},"roundingRule":{"$ref":"#/components/schemas/IntegerType"},"roundingMode":{"$ref":"#/components/schemas/RoundingMode"},"minimumMarkPrice":{"$ref":"#/components/schemas/DoubleType"},"settlement":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}},"description":"Internal reference is always required. If the proposal does not already have settlement instructions for the approving party, settlement is required. When a Lender is approving, the rounding rule, rounding mode are required. For non-OCC loans, minimum mark price is also required."},"Loans":{"type":"array","items":{"$ref":"#/components/schemas/Loan"}},"LoanSplit":{"required":["lastUpdateDateTime","loanSplitId","loanSplitStatus"],"type":"object","properties":{"loanSplitId":{"$ref":"#/components/schemas/LoanSplitId"},"loanSplitStatus":{"$ref":"#/components/schemas/LoanSplitStatus"},"loanId":{"$ref":"#/components/schemas/LoanId"},"splitLots":{"type":"array","items":{"$ref":"#/components/schemas/LoanSplitLot"}},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"},"createDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"LoanSplitId":{"type":"string","description":"The unique identifier of a loan split - UUID"},"LoanSplitLot":{"required":["internalReference","quantity"],"type":"object","properties":{"loanId":{"$ref":"#/components/schemas/LoanId"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"internalReference":{"$ref":"#/components/schemas/InternalReference"},"settlement":{"$ref":"#/components/schemas/PartySettlementInstruction"}}},"LoanSplitLotAcknowledge":{"required":["internalReference","loanId"],"type":"object","properties":{"loanId":{"$ref":"#/components/schemas/LoanId"},"internalReference":{"$ref":"#/components/schemas/InternalReference"}}},"LoanSplitProposal":{"type":"array","items":{"$ref":"#/components/schemas/LoanSplitProposalLot"}},"LoanSplitProposalLot":{"type":"object","properties":{"quantity":{"$ref":"#/components/schemas/IntegerType"},"internalReference":{"$ref":"#/components/schemas/InternalReference"},"settlement":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}}},"LoanSplitAcknowledgment":{"type":"array","items":{"$ref":"#/components/schemas/LoanSplitLotAcknowledge"}},"LoanSplitStatus":{"type":"string","enum":["PROPOSED","APPLIED"]},"LoanStatus":{"type":"string","description":"Loan state on the ledger.\n\nTypical happy path: `PROPOSED` → `PENDING` → `OPEN` → `CLOSED`.\n\n- `PROPOSED` — loan proposed, awaiting counterparty approval.\n- `PENDING` — approved, pending settlement (`settlement[].settlementStatus` is `PENDING` until both parties settle).\n- `OPEN` — both parties marked settlement `SETTLED` (`LOAN_OPENED`).\n- `CLOSED` — loan closed (fully returned or unwind approved).\n\nSee the **loans** tag description for the full transition table.\n","enum":["PROPOSED","PENDING","CANCEL_PENDING","CANCELED","UNWIND_PENDING","DECLINED","OPEN","CLOSED"]},"MarkDelta":{"required":["markDate","markValue"],"type":"object","properties":{"markValue":{"$ref":"#/components/schemas/DoubleType"},"markDate":{"$ref":"#/components/schemas/DateType"}}},"Parties":{"type":"array","items":{"$ref":"#/components/schemas/Party"}},"Party":{"required":["gleifLei","partyId","partyType"],"type":"object","properties":{"partyId":{"$ref":"#/components/schemas/PartyId"},"partyName":{"type":"string"},"partyType":{"$ref":"#/components/schemas/PartyType"},"gleifLei":{"type":"string"},"internalPartyId":{"type":"string"}}},"PartyId":{"type":"string","description":"The unique identifier of a party - UUID"},"PartyRole":{"type":"string","enum":["BORROWER","LENDER","TRIPARTY","CCP","VENUE","OPERATOR"]},"PartySettlementInstruction":{"required":["instruction","partyRole"],"type":"object","properties":{"partyRole":{"$ref":"#/components/schemas/PartyRole"},"settlementStatus":{"$ref":"#/components/schemas/SettlementStatus"},"internalAccountCode":{"type":"string"},"instruction":{"$ref":"#/components/schemas/SettlementInstruction"}}},"PartySettlementInstructionUpdate":{"required":["instruction","partyRole"],"type":"object","properties":{"partyRole":{"$ref":"#/components/schemas/PartyRole"},"internalAccountCode":{"type":"string"},"instruction":{"$ref":"#/components/schemas/SettlementInstruction"}}},"PartyType":{"type":"string","enum":["VENUE","CLIENT","OPERATOR"]},"Prepay":{"required":["currency","value"],"type":"object","properties":{"prepayIndicator":{"$ref":"#/components/schemas/YesNoType"},"prepayDate":{"$ref":"#/components/schemas/DateType"},"prepayRate":{"$ref":"#/components/schemas/DoubleType"}},"description":"Prepay defines details of non-cash pre-payemnts to the Lender"},"Price":{"required":["currency","value"],"type":"object","properties":{"value":{"$ref":"#/components/schemas/DoubleType"},"currency":{"$ref":"#/components/schemas/CurrencyCd"},"priceBasis":{"$ref":"#/components/schemas/PriceBasis"},"valueDate":{"$ref":"#/components/schemas/DateType"},"source":{"$ref":"#/components/schemas/PriceSource"}},"description":"Price is ignored for trade agreements and loan proposals"},"PriceBasis":{"type":"number","enum":[1,100]},"PriceSource":{"type":"string","enum":["1SOURCE","OCC"]},"Rate":{"type":"object","oneOf":[{"$ref":"#/components/schemas/RebateRate"},{"$ref":"#/components/schemas/FeeRate"}]},"Rates":{"type":"object","properties":{"rates":{"type":"array","items":{"$ref":"#/components/schemas/Rate"}}}},"RebateRate":{"type":"object","properties":{"rebate":{"oneOf":[{"$ref":"#/components/schemas/FixedRate"},{"$ref":"#/components/schemas/FloatingRate"}]}}},"RecallAcknowledgement":{"required":["acknowledgementType"],"type":"object","properties":{"acknowledgementType":{"$ref":"#/components/schemas/AcknowledgementType"},"description":{"type":"string"},"recallInternalReference":{"$ref":"#/components/schemas/InternalReference"}}},"Recall":{"required":["lastUpdateDateTime","loanId","quantity","recallId","status"],"type":"object","properties":{"recallId":{"$ref":"#/components/schemas/RecallId"},"loanId":{"$ref":"#/components/schemas/LoanId"},"status":{"$ref":"#/components/schemas/RecallStatus"},"executionVenue":{"$ref":"#/components/schemas/Venue"},"openQuantity":{"$ref":"#/components/schemas/IntegerType"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"recallDate":{"$ref":"#/components/schemas/DateType"},"recallDueDate":{"$ref":"#/components/schemas/DateType"},"acknowledgementType":{"$ref":"#/components/schemas/AcknowledgementType"},"description":{"type":"string"},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"},"recallInternalReferences":{"type":"array","items":{"$ref":"#/components/schemas/RecallPartyInternalReference"}},"createDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"RecallId":{"type":"string","description":"The unique identifier of an open recall - UUID"},"RecallPartyInternalReference":{"type":"object","properties":{"partyRole":{"$ref":"#/components/schemas/PartyRole"},"recallInternalReference":{"$ref":"#/components/schemas/InternalReference"}}},"RecallInternalReferenceUpdate":{"required":["recallInternalReference"],"type":"object","properties":{"recallInternalReference":{"type":"string"}}},"RecallProposal":{"required":["quantity","recallDate"],"type":"object","properties":{"executionVenue":{"$ref":"#/components/schemas/Venue"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"recallDate":{"$ref":"#/components/schemas/DateType"},"recallDueDate":{"$ref":"#/components/schemas/DateType"},"recallInternalReference":{"$ref":"#/components/schemas/InternalReference"}},"description":"The effective date of the recall. The securities are expected to be returned on the recallDate."},"RecallQuantityUpdate":{"required":["quantity"],"type":"object","properties":{"quantity":{"$ref":"#/components/schemas/IntegerType"}}},"Recalls":{"type":"array","items":{"$ref":"#/components/schemas/Recall"}},"RecallStatus":{"type":"string","enum":["OPEN","CLOSED","CANCELED"]},"Rerate":{"required":["lastUpdateDateTime","loanId","rate","rerate","rerateId","status"],"type":"object","properties":{"rerateId":{"$ref":"#/components/schemas/RerateId"},"loanId":{"$ref":"#/components/schemas/LoanId"},"status":{"$ref":"#/components/schemas/RerateStatus"},"statusReason":{"oneOf":[{"$ref":"#/components/schemas/RerateCancelErrorResponse"},{"$ref":"#/components/schemas/RerateDeclineErrorResponse"}]},"executionVenue":{"$ref":"#/components/schemas/Venue"},"isInitiator":{"type":"boolean"},"rate":{"$ref":"#/components/schemas/Rate"},"rerate":{"$ref":"#/components/schemas/Rate"},"dateProposed":{"$ref":"#/components/schemas/DateType"},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"RerateCancelErrorReason":{"type":"string","enum":["NO_RESPONSE"]},"RerateCancelErrorResponse":{"required":["reason"],"type":"object","properties":{"reason":{"$ref":"#/components/schemas/RerateCancelErrorReason"}}},"RerateDeclineErrorReason":{"type":"string","enum":["INCORRECT_RERATE_INFO","UNKNOWN_RERATE"]},"RerateDeclineErrorReasonFieldType":{"type":"string","description":"Rerate Decline Error Reason Field Types and Expected Values:\n * `RERATE` - [RebateRate](1.3.0#/schemas/RebateRate) or [FeeRate](1.3.0#/schemas/FeeRate) object.\n","enum":["RERATE_VALUE"]},"RerateDeclineErrorReasonFieldValue":{"required":["field"],"type":"object","properties":{"field":{"$ref":"#/components/schemas/RerateDeclineErrorReasonFieldType"},"expectedValue":{"oneOf":[{"$ref":"#/components/schemas/RebateRate"},{"$ref":"#/components/schemas/FeeRate"}]}}},"RerateDeclineErrorResponse":{"required":["reason"],"type":"object","properties":{"reason":{"$ref":"#/components/schemas/RerateDeclineErrorReason"},"error":{"$ref":"#/components/schemas/RerateDeclineErrorReasonFieldValue"}}},"RerateId":{"type":"string","description":"The unique identifier of a proposed rerate - UUID"},"RerateProposal":{"required":["loanId","rate"],"type":"object","properties":{"executionVenue":{"$ref":"#/components/schemas/Venue"},"rate":{"$ref":"#/components/schemas/Rate"}}},"Rerates":{"type":"array","items":{"$ref":"#/components/schemas/Rerate"}},"RerateStatus":{"type":"string","enum":["APPLIED","CANCEL_PENDING","CANCELED","DELETED","DECLINED","PENDING","PROPOSED"]},"Return":{"required":["lastUpdateDateTime","loanId","quantity","status"],"type":"object","properties":{"returnId":{"$ref":"#/components/schemas/ReturnId"},"loanId":{"$ref":"#/components/schemas/LoanId"},"status":{"$ref":"#/components/schemas/ReturnStatus"},"executionVenue":{"$ref":"#/components/schemas/Venue"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"collateral":{"$ref":"#/components/schemas/Collateral"},"settlementType":{"$ref":"#/components/schemas/SettlementType"},"returnDate":{"$ref":"#/components/schemas/DateType"},"settlementDate":{"$ref":"#/components/schemas/DateType"},"acknowledgementType":{"$ref":"#/components/schemas/AcknowledgementType"},"description":{"type":"string"},"settlement":{"type":"array","items":{"$ref":"#/components/schemas/PartySettlementInstruction"}},"lastUpdateDateTime":{"$ref":"#/components/schemas/DateTimeType"},"returnInternalReferences":{"type":"array","items":{"$ref":"#/components/schemas/ReturnPartyInternalReference"}},"doNotInstruct":{"type":"boolean"},"createDateTime":{"$ref":"#/components/schemas/DateTimeType"}}},"ReturnAcknowledgement":{"required":["acknowledgementType"],"type":"object","properties":{"acknowledgementType":{"$ref":"#/components/schemas/AcknowledgementType"},"description":{"type":"string"},"settlement":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"},"returnInternalReference":{"$ref":"#/components/schemas/InternalReference"}}},"ReturnId":{"type":"string","description":"The unique identifier of a pending return - UUID"},"ReturnInternalReferenceUpdate":{"required":["returnInternalReference"],"type":"object","properties":{"returnInternalReference":{"type":"string"}}},"ReturnPartyInternalReference":{"type":"object","properties":{"partyRole":{"$ref":"#/components/schemas/PartyRole"},"returnInternalReference":{"$ref":"#/components/schemas/InternalReference"}}},"ReturnProposal":{"required":["collateralValue","executionVenue","quantity","returnDate","returnSettlementDate","settlementType"],"type":"object","properties":{"executionVenue":{"$ref":"#/components/schemas/Venue"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"returnDate":{"$ref":"#/components/schemas/DateType"},"returnSettlementDate":{"$ref":"#/components/schemas/DateType"},"collateralValue":{"$ref":"#/components/schemas/DoubleType"},"settlementType":{"$ref":"#/components/schemas/SettlementType"},"settlement":{"type":"array","items":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}},"returnInternalReference":{"$ref":"#/components/schemas/InternalReference"},"doNotInstruct":{"type":"boolean"}},"description":"The collateral value of the shares being returned, in the collateral currency on the loan loan."},"Returns":{"type":"array","items":{"$ref":"#/components/schemas/Return"}},"ReturnSortField":{"type":"string","enum":["LASTUPDATEDATE","CREATEDATETIME"]},"ReturnStatus":{"type":"string","enum":["PENDING","CANCELED","SETTLED","UNWIND_PENDING"]},"RoundingMode":{"type":"string","description":"Required when Lender proposes","enum":["ALWAYSUP","ALWAYSDOWN","STANDARD","EXACT"]},"SettlementInstruction":{"required":["settlementBic"],"type":"object","properties":{"settlementBic":{"type":"string","description":"Business Identifier Code (BIC) used to identify Place of Settlement (PSET)"},"localAgentBic":{"type":"string","description":"BIC used to identify local agent that will interact with PSET"},"localAgentName":{"type":"string","description":"Name of local agent that will interact with PSET"},"localAgentAccount":{"type":"string","description":"Account within local agent that will interact with PSET"},"dtcParticipantNumber":{"$ref":"#/components/schemas/DtcPartipantNumber"},"cdsCustomerUnitId":{"$ref":"#/components/schemas/CdsCustomerUnitId"},"custodianName":{"type":"string","description":"Custodian Bank Name"},"custodianBic":{"type":"string","description":"Custodian Bank BIC"},"custodianAccount":{"type":"string","description":"Custodian Bank Account"}},"description":"* `dtcParticipantNumber` - Required if settlementBic = DTCYUS33 * `cdsCustomerUnitId` - Required if settlementBic = CDSLCATT \n"},"SettlementInstructionUpdate":{"required":["settlement"],"type":"object","properties":{"settlement":{"$ref":"#/components/schemas/PartySettlementInstructionUpdate"}}},"SettlementStatus":{"type":"string","enum":["NONE","PENDING","SETTLED"]},"SettlementStatusUpdate":{"required":["settlementStatus"],"type":"object","properties":{"settlementStatus":{"$ref":"#/components/schemas/SettlementStatus"}}},"SettlementType":{"type":"string","enum":["DVP","FOP"]},"SortOrder":{"type":"string","enum":["ASCENDING","DESCENDING"]},"TermType":{"type":"string","enum":["OPEN","FIXED","EVERGREEN","OVERNIGHT","EXTENDABLE"]},"TradeAgreement":{"required":["billingCurrency","collateral","dividendRatePct","instrument","quantity","rate","settlementDate","settlementType","termType","tradeDate","transactingParties"],"type":"object","properties":{"venues":{"$ref":"#/components/schemas/Venues"},"instrument":{"$ref":"#/components/schemas/Instrument"},"rate":{"$ref":"#/components/schemas/Rate"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"openQuantity":{"$ref":"#/components/schemas/IntegerType"},"billingCurrency":{"$ref":"#/components/schemas/CurrencyCd"},"dividendRatePct":{"$ref":"#/components/schemas/DoubleType"},"tradeDate":{"$ref":"#/components/schemas/DateType"},"termType":{"$ref":"#/components/schemas/TermType"},"termDate":{"$ref":"#/components/schemas/DateType"},"resetDate":{"$ref":"#/components/schemas/DateType"},"settlementDate":{"$ref":"#/components/schemas/DateType"},"settlementType":{"$ref":"#/components/schemas/SettlementType"},"collateral":{"$ref":"#/components/schemas/Collateral"},"transactingParties":{"$ref":"#/components/schemas/TransactingParties"},"doNotInstruct":{"type":"boolean"},"ccpIndicator":{"$ref":"#/components/schemas/CcpIndicator"}},"description":"Term Date required when Term Type is FIXED, EVERGREEN, OVERNIGHT, EXTENDABLE. Reset Date is required when Term Type is EVERGREEN or EXTENDABLE"},"TradeAmendment":{"type":"object","properties":{"billingCurrency":{"$ref":"#/components/schemas/CurrencyCd"},"dividendRatePct":{"$ref":"#/components/schemas/DoubleType"},"termType":{"$ref":"#/components/schemas/TermType"},"termDate":{"$ref":"#/components/schemas/DateType"},"resetDate":{"$ref":"#/components/schemas/DateType"},"settlementType":{"$ref":"#/components/schemas/SettlementType"},"ccpIndicator":{"$ref":"#/components/schemas/CcpIndicator"},"collateral":{"$ref":"#/components/schemas/CollateralAmendment"}},"description":"Term Date required when Term Type is FIXED"},"TransactingParty":{"required":["internalReference","party","partyRole"],"type":"object","properties":{"partyRole":{"$ref":"#/components/schemas/PartyRole"},"party":{"$ref":"#/components/schemas/Party"},"internalReference":{"$ref":"#/components/schemas/InternalReference"}}},"TransactingParties":{"type":"array","items":{"$ref":"#/components/schemas/TransactingParty"}},"Venue":{"required":["party","venueRefKey"],"type":"object","properties":{"party":{"$ref":"#/components/schemas/Party"},"venueRefKey":{"type":"string","description":"The unique id or key assigned by the venue"},"transactionDateTime":{"$ref":"#/components/schemas/DateTimeType"}},"description":"Venues are third-party services that generate loans, returns, recalls, rerates, or perform loan modifications on a clients behalf. A party with a valid ID and LEI is required."},"VenueReferenceKeyUpdate":{"required":["venueRefKey"],"type":"object","properties":{"venueRefKey":{"type":"string"}}},"Venues":{"type":"array","items":{"$ref":"#/components/schemas/Venue"}},"VenueTradeAgreement":{"required":["collateral","instrument","quantity","rate","tradeDate","transactingParties"],"type":"object","properties":{"executionVenue":{"$ref":"#/components/schemas/Venue"},"instrument":{"$ref":"#/components/schemas/Instrument"},"rate":{"$ref":"#/components/schemas/Rate"},"quantity":{"$ref":"#/components/schemas/IntegerType"},"billingCurrency":{"$ref":"#/components/schemas/CurrencyCd"},"dividendRatePct":{"$ref":"#/components/schemas/DoubleType"},"tradeDate":{"$ref":"#/components/schemas/DateType"},"termType":{"$ref":"#/components/schemas/TermType"},"termDate":{"$ref":"#/components/schemas/DateType"},"settlementDate":{"$ref":"#/components/schemas/DateType"},"settlementType":{"$ref":"#/components/schemas/SettlementType"},"collateral":{"$ref":"#/components/schemas/Collateral"},"transactingParties":{"$ref":"#/components/schemas/TransactingParties"}}},"YesNoType":{"type":"string","enum":["Y","N"]},"loans_loanId_body":{"oneOf":[{"$ref":"#/components/schemas/InternalReferenceUpdate"},{"$ref":"#/components/schemas/VenueReferenceKeyUpdate"},{"$ref":"#/components/schemas/SettlementStatusUpdate"},{"$ref":"#/components/schemas/SettlementInstructionUpdate"}]},"returns_returnId_body":{"oneOf":[{"$ref":"#/components/schemas/SettlementStatusUpdate"},{"$ref":"#/components/schemas/ReturnInternalReferenceUpdate"}]},"recalls_recallId_body":{"oneOf":[{"$ref":"#/components/schemas/RecallQuantityUpdate"},{"$ref":"#/components/schemas/RecallInternalReferenceUpdate"}]}},"responses":{"Success":{"description":"Operation was successful","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"Created":{"description":"Operation was successful","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"BadRequest":{"description":"Bad request or more information needed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"Unauthorized":{"description":"Not authorized to do this operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"NotFound":{"description":"Resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"Conflict":{"description":"Conflict with the state of the resource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"NotAllowed":{"description":"Operation not allowed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}},"Error":{"description":"An error occurred","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LedgerResponse"}}}}},"requestBodies":{"DelegationProposal":{"description":"Define a new venue delegate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DelegationProposal"}}},"required":true},"LoanAmendmentProposal":{"description":"Loan amendment proposed for updating the ledger","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanAmendmentProposal"}}},"required":true},"LoanAmendmentProposalCancel":{"description":"Provide reason and details for declining loan amendment proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanCancelErrorResponse"}}},"required":true},"LoanAmendmentProposalDecline":{"description":"Provide reason and details for declining loan amendment proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanDeclineErrorResponse"}}},"required":true},"LoanProposal":{"description":"New loan proposed for inclusion in the ledger","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanProposal"}}},"required":true},"LoanProposalApproval":{"description":"Update settlement instructions on an existing loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanProposalApproval"}}},"required":true},"LoanProposalCancel":{"description":"Reason for canceling a proposed loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanCancelErrorResponse"}}},"required":true},"LoanProposalDecline":{"description":"Provide reason and details for declining loan proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanDeclineErrorResponse"}}},"required":true},"LoanSplitProposal":{"description":"Split proposed against loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanSplitProposal"}}},"required":true},"LoanSplitAcknowledgment":{"description":"Split proposed against loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoanSplitAcknowledgment"}}},"required":true},"Party":{"description":"Define a new party on the ledger","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Party"}}},"required":true},"RerateProposal":{"description":"New rerate proposed against loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RerateProposal"}}},"required":true},"RecallProposal":{"description":"New recall proposed against loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecallProposal"}}},"required":true},"RecallAcknowledgement":{"description":"Acknowledge return with positive/negative intent","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecallAcknowledgement"}}},"required":true},"RerateProposalCancel":{"description":"Provide reason for canceling a rerate proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RerateCancelErrorResponse"}}},"required":true},"RerateProposalDecline":{"description":"Provide reason and details for declining rerate proposal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RerateDeclineErrorResponse"}}},"required":true},"ReturnAcknowledgement":{"description":"Acknowledge return with positive/negative intent","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnAcknowledgement"}}},"required":true},"ReturnProposal":{"description":"New return proposed against loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ReturnProposal"}}},"required":true},"SettlementInstructionUpdate":{"description":"Update settlement instructions on an existing loan","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SettlementInstructionUpdate"}}},"required":true},"TradeAgreement":{"description":"Agreement from a execution venue introduced to the ledger","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeAgreement"}}},"required":true}},"headers":{"AgreementId":{"schema":{"type":"string","description":"The unique identifier of a trade agreement - UUID"}},"BuyinCompleteId":{"schema":{"type":"string","description":"The unique identifier of a complete buyin - UUID"}},"BuyinInitiateId":{"schema":{"type":"string","description":"The unique identifier of an initiated buyin - UUID"}},"LoanId":{"schema":{"type":"string","description":"The unique identifier of a loan - UUID"}},"ReturnId":{"schema":{"type":"string","description":"The unique identifier of a return - UUID"}},"RecallId":{"schema":{"type":"string","description":"The unique identifier of a recall - UUID"}},"RerateId":{"schema":{"type":"string","description":"The unique identifier of a rerate - UUID"}}},"securitySchemes":{"stage_auth":{"type":"oauth2","flows":{"authorizationCode":{"authorizationUrl":"https://stageauth.equilend.com/auth/realms/1Source/protocol/openid-connect/auth","tokenUrl":"https://stageauth.equilend.com/auth/realms/1Source/protocol/openid-connect/token","scopes":{}}}}}}}