GET by Email

GET /participants/:email

const getParticipants = () => {
  const timestamp = Math.round(Date.now() / 1000)
  const payload = timestamp + 'GET' + '/participants/{email}' + '{}'
  const decodedSecret = Buffer.from(apiSecret, 'base64')
  const hmac = crypto.createHmac('sha256', decodedSecret)
  const signedPayload = hmac.update(payload).digest('base64')

  // SET HEADERS
 const headers = {
    'X-NDAX-API-KEY': 'public_key',
    'X-NDAX-SIGNED': signedPayload,
    'X-NDAX-TIMESTAMP': timestamp,
    'X-NDAX-PASSPHRASE': 'passphrase'
  }
  const options = {
    headers,
    body,
    json: true
  }

  return request.get('https://api.ndax.in/participants/{email}', options)
}

Sample Response

{
  "message": {
    "participant_code": "ABCDEF",
    "email": "customer@admin.com"
  }
}

Returns a participant to which you are associated by an email. As an alternative to using the email query parameter described above within the GET /participants endpoint, this is a lighter-weight and dedicated endpoint to filter participants by email.

Query parameters include:

  • email filters to a particular email

Response parameters listed below

ParameterDescriptionType

participant_code

Unique participant code

string

email

Email associated with the participant

string

Last updated