How to update the throughput of the existing container using nodejs (javascript SDK)?
Referrences: https://docs.microsoft.com/en-us/azure/cosmos-db/set-throughput#update-throughput-on-a-database-or-a-container
Please check the below REST API request:
curl -X PUT \
https://mydbinstance.documents.azure.com/offers/pSMeVMS0g3fc= \
-H 'Accept: */*' \
-H 'Cache-Control: no-cache' \
-H 'Connection: keep-alive' \
-H 'Content-Type: application/json' \
-H 'Host: mydbinstance.documents.azure.com' \
-H 'authorization: type=master&ver=1.0&sig=XE8P49N9Y9yhny09yYJY690N9th9JOIHYnh9N8N89NTHn*TjH=' \
-H 'content-length: 266' \
-H 'x-ms-date: Fri, 03 May 2019 10:05:06 GMT' \
-H 'x-ms-version: 2016-07-11' \
-d '{
"id": "pSMeVMS0g3fc=",
"_rid": "pSMeVMS0g3fc=",
"_self": "offers/pSMeVMS0g3fc=/",
"offerVersion": "V2",
"resource": "dbs/pNZpAA==/colls/pSMeVMS0g3fc=/",
"content": {
"offerThroughput": 4000
},
"offerResourceId": "pSMeVMS0g3fc="
} '
Error Response: The input authorization token can't serve the request. Please check that the expected payload is built as per the protocol, and check the key being used.