4
const rp = require('request-promise');
const https = require('https');

const agentOptions = {
                    host: 'localhost',
                    port: 443,
                    path: '/',
                    rejectUnauthorized: false,
                    secureProtocol: 'TLSv1_method'
                };

                const agent = new https.Agent(agentOptions);

                const options = {
                    method: 'POST',
                    url: 'https://sandbox-us-api.experian.com/consumerservices/social-search/v1/social-search',
                    headers: request.headers,
                    body: request.payload,
                    json: true,
                    agent: agent
                };

const res = await rp(options);

Upon running this in Postman using the URL: http://localhost:443/experian/social_search/get , I get an error of:

Error: write EPROTO 105840:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:c:\ws\deps\openssl\openssl\ssl\record\ssl3_record.c:332:

The Experian Third Party API does not use self signed. And I was able to run the sandbox URL in the Postman.

Anyone have any ideas what is the problem?

Dessa
  • 237
  • 3
  • 13

0 Answers0