Get business document by ID and account ID
GEThttps://api.publicsquare.com/accounts/:accountId/business-documents/:id
Get a business document by ID and account ID.
Permissions
business:read
Request
Path Parameters
accountId stringrequired
id stringrequired
Responses
- 200
- 400
- 401
- 403
- 404
OK
- application/json
- Schema
- Example (auto)
Schema
idstringnullable
Business Document ID
Example:
doc_BK44jiqsyJvWK3xH7pMaPd6qK
account_idstringnullable
Account ID
Example:
acc_B518niGwGYKzig6vtrRVZGGGV
typestringnullable
Document type
Example:
proof_of_business
content_typestringnullable
Document content type
Example:
application/pdf
opt_outbooleannullable
If true, the document is not required
Example:
false
sizeint64nullable
Size of the document in bytes
Example:
1048576
filenamestringnullable
Filename of the document
Example:
sample.pdf
entity_idstringnullable
ID of the entity or person the document is associated with
Example:
ent_5mQSxcSAW3UZ4ijLzEt4RuAib
entity_typestringnullable
Type or role of entity the document is associated with
Example:
business_representative
created_atdate-timenullable
Date document was created
Example:
2024-06-30T01:02:29.212Z
modified_atdate-timenullable
Date document was modified
Example:
2024-06-30T01:02:29.212Z
{
"id": "doc_BK44jiqsyJvWK3xH7pMaPd6qK",
"account_id": "acc_B518niGwGYKzig6vtrRVZGGGV",
"type": "proof_of_business",
"content_type": "application/pdf",
"opt_out": false,
"size": 1048576,
"filename": "sample.pdf",
"entity_id": "ent_5mQSxcSAW3UZ4ijLzEt4RuAib",
"entity_type": "business_representative",
"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/accounts/:accountId/business-documents/: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