Get privacy policy
                GET https://{domainname}/client/v1/{customerId}/services/privacypolicy
            
            Services
Request
This call lets you request the privacy policy for a specific or all payment products in your account.
Query parameters
Query parameters for this method
| Property | Type | Required | Repeat | Details | 
|---|---|---|---|---|
| locale | string | no | no | read close | 
| 
		
			close
		
		 DescriptionLocale in which the privacy policy should be returned. Uses your default locale when none is provided. | ||||
| paymentProductId | integer | no | no | read close | 
| 
		
			close
		
		 DescriptionID of the payment product for which you wish to retrieve the privacy policy. When no ID is provided you will receive all privacy policies for your payment products.  | ||||
Request example
                    SDK: JavaScript
                    
                    
        
        This scenario you will probably use the most
- 
                        // In order to call this method, you must initialize the Session first. const options: GetPrivacyPolicyOptions = { locale: "en_US", paymentProductId: 1, }; try { const { htmlContent } = await session.getPrivacyPolicy(options); // Process customer details } catch (err) { // Indicate that an error occurred }
Responses
The response contains the HTML for the privacy policy.
Response 200 - OKGetPrivacyPolicyResponse
Your request was exectued successfully and the response contains any applicable privacy policy texts
| 
							
									Properties
							
							 | |||
| Property | Type | Required | Details | 
|---|---|---|---|
| htmlContent | string | no | read close | 
| 
		
			close
		
		 DescriptionHTML content to be displayed to the user | |||
Response example
                        SDK: JavaScript
                        
                        
                
                This scenario you will probably use the most
- 
                        { "htmlContent" : "<h1>Privacy Notice</h1>\n..." }
Response 400 - Bad requestErrorResponse
| 
							
									Properties
							
							 | |||
| Property | Type | Required | Details | 
|---|---|---|---|
| errorId | string | yes | read close | 
| 
		
			close
		
		 DescriptionUnique reference, for debugging purposes, of this error response | |||
| array of object | yes | read close | |
| 
		
			close
		
		 DescriptionList of one or more errors | |||
| object | no | read close | |
| category | string | no | read close | 
| 
		
			close
		
		 DescriptionCategory the error belongs to. The category should give an indication of the type of error you are dealing with.
Possible values:
 
 | |||
| code | string | yes | read close | 
| 
		
			close
		
		 DescriptionError code | |||
| httpStatusCode | integer | no | read close | 
| 
		
			close
		
		 DescriptionHTTP status code for this error that can be used to determine the type of error | |||
| id | string | no | read close | 
| 
		
			close
		
		 DescriptionID of the error. This is a short human-readable message that briefly describes the error. | |||
| message | string | no | read close | 
| 
		
			close
		
		 DescriptionHuman-readable error message that is not meant to be relayed to customer as it might tip off people who are trying to commit fraud | |||
| propertyName | string | no | read close | 
| 
		
			close
		
		 DescriptionReturned only if the error relates to a value that was missing or incorrect. Contains a location path to the value as a JSonata query. Some common examples: 
 | |||
| requestId | string | no | read close | 
| 
		
			close
		
		 DescriptionID of the request that can be used for debugging purposes | |||
Response example
                        SDK: JavaScript
                        
                        
                
                This schenario you will probably use the most
- 
                        { "errorId" : "5c6d4ec2ca444060d13f3ff2d0647fb1", "errors" : [ { "code" : "1024", "id" : "SERVICE_NOT_ALLOWED", "category" : "CONNECT_PLATFORM_ERROR", "message" : "The requested service is not available.", "httpStatusCode" : 400 } ] }