Module results

For asynchronous modules (MFA, for example) and for post-hoc queries of synchronous modules (Score and Insights, for example), Connect provides one route: by Analysis ID.


Search by Analysis ID

This route returns the execution status of the contracted modules by Analysis ID.

📘

Our service addresses:

Homologation:

GET https://homologapix.clearsale.com.br/connect/v1/integration/analysis/[analysisId]

Production:

GET https://apix.clearsale.com.br/connect/v1/integration/analysis/[analysisId]


Endpoint Authentication

The endpoint requires authentication. Clients must provide valid credentials so the system can successfully authenticate and transmit data.

Supported Authentication Method: Bearer Token (JWT)

Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...

📘

Details about the authentication process and how to obtain a token can be found in Authentication.


Error Response

Represents the details of a problem returned by the API in case of an error.

Fields

FieldDescriptionTypeRequired
typeURI that identifies the specific type of problem. Can be used to categorize the error.StringNo
titleDescriptive title of the problemStringYes
statusHTTP status code associated with the problemIntegerYes
instanceURI that identifies the specific instance of the problemStringNo

HTTP Status Codes

Represents the possible HTTP codes returned by the API in case of an error.

CodeNameMeaning
400Bad RequestThe request was malformed or contains invalid parameters
401UnauthorizedThe client is not authenticated or the token is invalid/expired
404Not FoundThe requested resource was not found
500Internal Server ErrorAn unexpected error occurred on the server
503Service UnavailableThe service is temporarily unavailable or under maintenance

JSON Examples

{
    "title": "Fail to Validate Request.",
    "status": 400,
    "detail": "Invalid analysisId format. AnalysisId must be a valid Guid."
}
{
    "title": "Id not found",
    "status": 404,
    "detail": "Analysis 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx' Not Found."
}
{
    "type": "https://tools.ietf.org/html/rfc7231#section-6.5.1",
    "title": "Internal server error",
    "status": 500,
    "detail": "The server encountered an unexpected condition that prevented it from fulfilling the request",
    "traceId": "string"
}

Webhook Flow

The webhook allows the system to send automatic notifications to an endpoint defined by the client whenever a specific action or event occurs in one of the asynchronous modules. This feature is essential to ensure that the client receives real-time updates, integrating the data directly into their business flow.

To configure a webhook, you must provide:

  • The endpoint URL that should receive the data.

The available modules are:

Modules
MFA
Biolink

Retry Flow

If the integrator's URL returns any HTTP status other than 200 (OK), the Clearsale system will make new notification attempts for the same request.

These retries will continue until a response with status 200 is received, indicating successful processing. The interval between attempts will be progressively increased according to the number of previous failures, following a backoff strategy to avoid overloading the integrator's system.


Endpoint Authentication

If the provided endpoint requires authentication, the client must provide the necessary credentials so that the system can authenticate and send the data successfully. The supported authentication types are:

Basic Authentication The client must provide a username and password, which will be converted into a Base64 string and added to the request header.

Where dXN1YXJpbzpwYXNzZW5oYQ== is the Base64 encoding of user:password.

Bearer Token (JWT) The client must provide a valid JWT token.

Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...

🚧

Note: The system does not perform authentication to generate the token.

API Key The client must provide a key and value, which will be included in the request header as a key: value pair.

>


Request

POST https://exemple-clearsale.com.br/analysis-result
Content-Type: application/json 

{
  "analysisId": "string",
  "date": "2025-09-26T17:21:11.0367845Z",
  "type": "mfa" //module
}