fbpx

< / >

Reports

Reports

URL:

https://{{wolkvox_server}}/server/API/v2/custom/reports.php

Description:

The reports search API allows us to search for report records in the parameterized modules of our CRM by sending parameters.

How it works?:

This API works through a POST request, which requires the following fields for its proper functioning:

The request headers require the following information:

  • Wolkvox-Token

 

– In the request body, the following information is required:

  • operation
  • name
  • dateStart
  • dateEnd

REQUEST

KEY
DESCRIPTION
EXAMPLE
Wolkvox-Token
It is the token configured by the client on the CRM page.
{token}
operation
It is the name of the operation in the CRM.
{operation_name}
name
It is the name of the report, and it must be exactly the same as the name that was configured in the CRM.
{name}
dateStart
It is the initial range to generate the query.
yyyymmddhis
dateEnd
It is the final range to generate the query.
yyyymmddhis

RESPONSE

				
					<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://{{wolkvox_server}}/server/API/v2/custom/reports.php',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'{
    "operation":"{{operation}}",
    "name":"{{name}}",
    "dateStart":"{{yyyymmddhis}}",
    "dateEnd":"{{yyyymmddhis}}"
}',
  CURLOPT_HTTPHEADER => array(
    'Wolkvox-Token: {{Wolkvox-Token}}',
    'Content-Type: application/json'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

				
			
Posibles códigos de error

Usamos cookies, se continuar a navegar assumimos que concorda. Pode ler mais sobre a utilização de cookies nas nossas políticas de privacidade e tratamento de dados pessoais

We use cookies, if you continue browsing we will assume that you agree. You can read more about the use of cookies in our privacy policies and treatment of personal data