createQueryConfiguration

createQueryConfiguration

This method creates a query configuration for a specified scenario.

Parameters

  • scenarioId (string, required): The ID of the scenario for which the query configuration is being created.
  • query (object, required): The query configuration details.

Returns

A JSON object containing the details of the newly created query configuration.

Usage Example

const axios = require('axios');
let data = JSON.stringify({
  "query": {
    "type": "IDInformation",
    "requestId": 0,
    "attribute": "string",
    "value": true,
    "operator": "$noop"
  }
});

let config = {
  method: 'post',
  maxBodyLength: Infinity,
  url: 'https://api.nexera.id/compliance/scenarios/:scenarioId/queryConfigurations',
  headers: { 
    'Content-Type': 'application/json', 
    'Accept': 'application/json', 
    'Authorization': 'Bearer <TOKEN>'
  },
  data : data
};

axios.request(config)
.then((response) => {
  console.log(JSON.stringify(response.data));
})
.catch((error) => {
  console.log(error);
});