Perform operations using APIs
This article describes how to perform CRDP tasks using APIs.
Supported APIs
/v1/protect
to protect data/v1/reveal
to reveal protected data/v1/protectbulk
to protect data in bulk/v1/revealbulk
to reveal protected data in bulk
These APIs use the POST
method.
Prerequisites
CRDP is up and running. Refer to the following sections based on your deployment environment.
CipherTrust Manager is up and running. Refer to CipherTrust Manager Deployment for details.
Protection policy is created. Refer to Managing Protection Policy for details.
Key used in the protection policy is added to the Application Data Protection Clients Group with Use, Read, Encrypt, Decrypt, and Export permissions.
Authentication
CRDP supports requests with and without JWT authentication. You need to specify the <ip address>
of the host machine where the CRDP container is deployed and the <port>
of the CRDP container.
When using JWT authentication, you need to specify --header 'Authorization: Bearer <JWT Value>'
in the requests.
Example: Without JWT authentication
curl -X POST -H "Content-Type: application/json" -d '{"protection_policy_name": "<protection_policy>","data": "<data>"}' <ip>:<port>/v1/protect
Example: With JWT authentication
curl -X POST -H "Content-Type: application/json" --header 'Authorization: Bearer JWT' -d '{"protection_policy_name": "<protection_policy>","data": "<data>"}' <ip>:<port>/v1/protect
Request Parameters
Refer to API Reference for details on request and response parameters.