Create Share
Create a share record for data exchange between qid accounts
POST /di/share
Body
| Property | Type | Description |
|---|---|---|
templateId | string | Template ID for the share |
otherFields | Fields[] | Additional form fields |
participants | Participant[] | Accounts involved in the share |
status | string | Share status (open, completed, closed) |
Example request
curl --request POST 'https://api.qidpro.xyz/di/share' \
--header 'Authorization: Bearer your-secret-key' \
--header 'tokenId: your-token-id' \
--header 'Content-Type: application/json' \
--data '{
"templateId": "669d25bf4be6e965914a9e3e",
"otherFields": [
{
"label": "Purpose of Visit",
"name": "purpose_of_visit",
"value": "Work"
}
],
"status": "open",
"participants": [
{
"roles": ["organiser", "admin"],
"account_id": "6627c83c122f76583c42ff10",
"accountType": "organisation",
"accountSnapshot": {
"name": "Hotel Raj - Manali",
"displayPictureUrl": "c103be92343.jpeg"
},
"analytics": {
"gender": "male",
"age": 23,
"zipCode": "110030"
}
},
{
"roles": ["sharer", "admin"],
"account_id": "65dea5868910b6f5957a0fb5",
"accountType": "user",
"accountSnapshot": {
"name": "Manu Arya"
},
"sharedDocumentsIds": [
"65df7d42fdfc8d3689057d8e"
]
}
]
}'Participant fields
| Field | Description |
|---|---|
roles | Array of roles: organiser, admin, sharer |
account_id | qid account ID |
accountType | user or organisation |
accountSnapshot | Snapshot of account details at share creation |
sharedDocumentsIds | Document IDs shared by this participant |
analytics | Optional analytics metadata |
Updated 4 days ago
Did this page help you?