Get an item based on its itemId
The collection or table to be queried.
An object containing the retrieved item
curl -X POST 'https://mysql-adapter.com/data/get' \
--header 'Content-Type: application/json' \
--data-raw '{
"requestContext": {
"settings": {
"secretKey": "mySecureSecret"
},
"instanceId": "12a345b6-7890-98d7-65e4-f321abc1de23",
"installationId": "987fe654-3d21-4def-ab5c-6d78e90f123a",
"memberId": "77aa88bb-2c2c-d3d3-4e4e-ff55aa66bb77",
"role": "OWNER"
},
"collectionName": "car",
"itemId": "86cbf595-d369-48bb-8649-c6c082c003ca"
}'
{
"item": {
"_id": "86cbf595-d369-48bb-8649-c6c082c003ca",
"_owner": "81c9168e-95b8-47fd-8e6a-ad9fdf71b38e",
"make": "Ford",
"model": "Mustang",
"year": 2001,
"date_added": { "$date": "2001-06-07T21:00:00.000Z" }
}
}
This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.