Unmask customer data
client.customers.unmasked(stringid, CustomerUnmaskedParams { correlationID, requestID, straddleAccountID } params?, RequestOptionsoptions?): CustomerUnmaskedV1 { data, meta, response_type }
/v1/customers/{id}/unmasked
Retrieves the unmasked details, including PII, of an existing customer. Supply the unique customer ID that was returned from your 'create customer' request, and Straddle will return the corresponding customer information. This endpoint needs to be enabled by Straddle and should only be used when absolutely necessary.
Parameters
id: string
Returns
Unmask customer data
import Straddle from '@straddlecom/straddle';
const client = new Straddle({
apiKey: 'My API Key',
});
const customerUnmaskedV1 = await client.customers.unmasked('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');
console.log(customerUnmaskedV1.data);
{
"data": {
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"created_at": "2019-12-27T18:11:19.117Z",
"email": "ron.swanson@pawnee.com",
"name": "Ron Swanson",
"phone": "+12128675309",
"status": "pending",
"type": "individual",
"updated_at": "2019-12-27T18:11:19.117Z",
"address": {
"address1": "123 Main St",
"city": "Anytown",
"state": "CA",
"zip": "12345",
"address2": "Apt 1"
},
"compliance_profile": {
"dob": "1969-04-20",
"ssn": "123-45-6789"
},
"config": {
"processing_method": "inline",
"sandbox_outcome": "standard"
},
"device": {
"ip_address": "192.168.1.1"
},
"external_id": "external_id",
"metadata": {
"foo": "string"
}
},
"meta": {
"api_request_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"api_request_timestamp": "2019-12-27T18:11:19.117Z"
},
"response_type": "object"
}Returns Examples
{
"data": {
"id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"created_at": "2019-12-27T18:11:19.117Z",
"email": "ron.swanson@pawnee.com",
"name": "Ron Swanson",
"phone": "+12128675309",
"status": "pending",
"type": "individual",
"updated_at": "2019-12-27T18:11:19.117Z",
"address": {
"address1": "123 Main St",
"city": "Anytown",
"state": "CA",
"zip": "12345",
"address2": "Apt 1"
},
"compliance_profile": {
"dob": "1969-04-20",
"ssn": "123-45-6789"
},
"config": {
"processing_method": "inline",
"sandbox_outcome": "standard"
},
"device": {
"ip_address": "192.168.1.1"
},
"external_id": "external_id",
"metadata": {
"foo": "string"
}
},
"meta": {
"api_request_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
"api_request_timestamp": "2019-12-27T18:11:19.117Z"
},
"response_type": "object"
}