Sensitives API
All URIs are relative to http://localhost:1000
Method | HTTP request | Description |
---|---|---|
sensitivesCreateNewSensitive | POST /sensitives/create | /sensitives/create [POST] |
sensitivesDeleteSensitive | POST /sensitives/{sensitive}/delete | /sensitives/{sensitive}/delete [POST] |
sensitivesSnapshot | GET /sensitives | /sensitives [GET] |
sensitivesCreateNewSensitive​
Sensitive sensitivesCreateNewSensitive()
This will create a new sensitive model.
Example​
import * as Pieces from '@pieces.app/pieces-os-client'
const configuration = Pieces.Configuration()
const apiInstance = new Pieces.SensitivesApi(configuration)
const body: Pieces.SensitivesCreateNewSensitiveRequest = {
// SeededSensitive (optional)
seededSensitive: ,
};
apiInstance.sensitivesCreateNewSensitive(body).then((data: Sensitive) => {
console.log('API called successfully. Returned data: ' + data)
}).catch((error: unknown) => console.error(error))
Parameters​
Name | Type | Description | Notes |
---|---|---|---|
seededSensitive | SeededSensitive |
Return type​
HTTP request headers​
- Content-Type: application/json
- Accept: application/json, text/plain
HTTP response details​
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |
sensitivesDeleteSensitive​
sensitivesDeleteSensitive()
This will delete a sensitive based on the sensitive uuid.
Example​
import * as Pieces from '@pieces.app/pieces-os-client'
const configuration = Pieces.Configuration()
const apiInstance = new Pieces.SensitivesApi(configuration)
const body: Pieces.SensitivesDeleteSensitiveRequest = {
// string | This is a uuid that represents a sensitive.
sensitive: sensitive_example,
};
apiInstance.sensitivesDeleteSensitive(body).then((data: void (empty response body)) => {
console.log('API called successfully. Returned data: ' + data)
}).catch((error: unknown) => console.error(error))
Parameters​
Name | Type | Description | Notes |
---|---|---|---|
sensitive | [string] | This is a uuid that represents a sensitive. | defaults to undefined |
Return type​
void (empty response body)
HTTP request headers​
- Content-Type: Not defined
- Accept: text/plain
HTTP response details​
Status code | Description | Response headers |
---|---|---|
204 | No Content | - |
500 | - |
sensitivesSnapshot​
Sensitives sensitivesSnapshot()
This will get a snapshot of all of the sensitives.
Example​
import * as Pieces from '@pieces.app/pieces-os-client'
const configuration = Pieces.Configuration()
const apiInstance = new Pieces.SensitivesApi(configuration)
apiInstance.sensitivesSnapshot().then((data: Sensitives) => {
console.log('API called successfully. Returned data: ' + data)
}).catch((error: unknown) => console.error(error))
Parameters​
This endpoint does not need any parameters.
Return type​
HTTP request headers​
- Content-Type: Not defined
- Accept: application/json, text/plain
HTTP response details​
Status code | Description | Response headers |
---|---|---|
200 | OK | - |
500 | Internal Server Error | - |