Update Application
This request updates an application, targeted by secure ID.
| patch | /push/applications/{application_sid} |
| put | /push/applications/{application_sid} |
Sample
A sample PATCH request to update the Application object, targeted by secure ID, with the values in the request body:
curl -X PATCH \
'https://api.carrierx.com/core/v2/push/applications/8b03edc1-5378-4c4e-a480-9015206089dc' \
-H 'Content-Type: application/json' \
--data-binary '{"name": "another name"}' \
-H 'Authorization: Bearer 5ebc03d6-8b2b-44ad-bf65-72d4f1491dda'
Response
200 status code with a serialized copy of the updated Application object:
{
"apns_id": null,
"apns_key_id": null,
"apns_p8": null,
"apns_p12": null,
"apns_p12_expiration": null,
"apns_p12_password": null,
"apns_team_id": null,
"apns_topic": null,
"application_sid": "8b03edc1-5378-4c4e-a480-9015206089dc",
"google_credentials": "L2hvbWUvdXNlci9Eb3dubG9hZHMvc2VydmljZS1hY2NvdW50LWZpbGUuanNvbgo="
"name": "another name",
"partner_sid": "e00430c3-a7d0-4666-ab5c-f7202448382f"
}
An Application object can be updated using either a PATCH or PUT request.
-
A
PATCHrequest can be used to update one or more attribute values. When using aPATCHrequest, only the attributes specified in the request payload will be updated, all other attributes and values will remain the same. The application secure ID is passed in the query URL, and the values to be modified are passed in the request body. -
A
PUTrequest can be used to update an entire Application object. The application secure ID is passed in the query URL, and the entire Application object is passed in the request body.
Note, while all the fields must be present in a PUT request, not all the attribute values may be modified after the initial creation, because when created, some of them become read-only.
Required Scopes
To update an Application object, the partner must have one of the following scopes enabled:
push.managepush.update
Path Arguments
| Parameter | Data Type | Description |
|---|---|---|
| application_sid required | string | The application secure ID. |
Body Arguments
JSON representation of the fields and values to be updated.
Fields that can be modified are:
apns_idapns_key_idapns_p8apns_p12apns_p12_passwordapns_team_idapns_topicgoogle_credentialsname
Refer to this table to view all fields that appear in the Application object.