Get contract by ID
GEThttps://api.publicsquare.com/contracts/:id
Get a contract by ID in the Account.
Permissions
business:read
Request
Path Parameters
id stringrequired
Responses
- 200
- 400
- 401
- 403
- 404
OK
- application/json
- Schema
- Example (auto)
Schema
idstringnullable
Contract ID
Example:
doc_BK44jiqsyJvWK3xH7pMaPd6qK
account_idstringnullable
Account ID
Example:
acc_B518niGwGYKzig6vtrRVZGGGV
productstringnullable
Product
Example:
payments
statusstringnullable
Contract status
Example:
signed
recipient_namestringnullable
Recipient name of digital contract
Example:
John Smith
recipient_emailstringnullable
Recipient email of digital contract
Example:
john.smith@email.com
recipient_urlstringnullable
Contract URL for reviewing and signing of contract
Example:
https://contractsigningurl.com/
created_atdate-timenullable
Date contract was created
Example:
2024-06-30T01:02:29.212Z
modified_atdate-timenullable
Date contract was modified
Example:
2024-06-30T01:02:29.212Z
{
"id": "doc_BK44jiqsyJvWK3xH7pMaPd6qK",
"account_id": "acc_B518niGwGYKzig6vtrRVZGGGV",
"product": "payments",
"status": "signed",
"recipient_name": "John Smith",
"recipient_email": "john.smith@email.com",
"recipient_url": "https://contractsigningurl.com/",
"created_at": "2024-06-30T01:02:29.212Z",
"modified_at": "2024-06-30T01:02:29.212Z"
}
Bad Request
- application/json
- Schema
- Example (auto)
Schema
errors objectnullable
typestringnullable
titlestringnullable
statusint32nullable
detailstringnullable
instancestringnullable
property name*any
{
"errors": {},
"type": "string",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string"
}
Unauthorized
- application/json
- Schema
- Example (auto)
Schema
typestringnullable
titlestringnullable
statusint32nullable
detailstringnullable
instancestringnullable
property name*any
{
"type": "string",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string"
}
Forbidden
- application/json
- Schema
- Example (auto)
Schema
typestringnullable
titlestringnullable
statusint32nullable
detailstringnullable
instancestringnullable
property name*any
{
"type": "string",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string"
}
Not Found
- application/json
- Schema
- Example (auto)
Schema
typestringnullable
titlestringnullable
statusint32nullable
detailstringnullable
instancestringnullable
property name*any
{
"type": "string",
"title": "string",
"status": 0,
"detail": "string",
"instance": "string"
}
Authorization: X-API-KEY
name: X-API-KEYtype: apiKeyscopes: business:read
description: Authorization by API Key inside request's X-API-KEY headerin: header
- csharp
- curl
- dart
- go
- http
- java
- javascript
- kotlin
- c
- nodejs
- objective-c
- ocaml
- php
- powershell
- python
- r
- ruby
- rust
- shell
- swift
- HTTPCLIENT
- RESTSHARP
var client = new HttpClient();
var request = new HttpRequestMessage(HttpMethod.Get, "https://api.publicsquare.com/contracts/:id");
request.Headers.Add("Accept", "application/json");
request.Headers.Add("X-API-KEY", "<X-API-KEY>");
var response = await client.SendAsync(request);
response.EnsureSuccessStatusCode();
Console.WriteLine(await response.Content.ReadAsStringAsync());
ResponseClear