Set Data Safety
set_data_safetyWrite an app's data safety declaration from an exported Play Console CSV. Preview then confirm, since the declaration cannot be read back.
Instructions
Write the data safety labels declaration of an app.
Supply EITHER csv_path (preferred) OR safety_labels, not both.
There is no API to read the current declaration back, so the CSV can only come from Play Console > App content > Data safety > Export to CSV, and that exported file is the only thing that could ever undo this write. Export one before you start.
A csv_path is checked before anything is sent, and the file is read again on the confirm leg — so the approval is bound to the answers, not to the path.
Disabled in read-only mode. Two-step: preview, then confirm.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| confirm | No | Set True only after the user approved the preview | |
| csv_path | No | Path to a CSV exported from Play Console | |
| package_name | Yes | App package name | |
| safety_labels | No | SafetyLabelsUpdateRequest body, i.e. {"safetyLabels": "<contents of the Data Safety CSV>"}. Structure is reported but not enforced on this path | |
| confirmation_token | No | The token from that preview; never invent one |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||