Skip to main content
Version: 1.0.0

The Webhook object

Webhook

A webhook allows you to automatically receive real-time information from our system. You can get notifications, invoices, or status updates instantly.

Endpoints

GET/v1/config/webhook/{webhookId}
PUT/v1/config/webhook/{webhookId}
DELETE/v1/config/webhook/{webhookId}
GET/v1/config/webhook
POST/v1/config/webhook

Information
All sensitive data stored in our database is encrypted to ensure maximum security.

Attributes
webhookIdstring (uuid) - Optional

filterStreamDirectionenum - Optional

labelstring (undefined (min: 3)) - Optional




Objects
{
  "filterStreamDirection": "OUTBOUND",
  "label": "My webhook configuration with basic auth",
  "adapterCode": "standardAdapter",
  "interopData": {
    "endpoints": {
      "status": {
        "callbackUrl": "https://myenpoint.com/status"
      },
      "invoice": {
        "callbackUrl": "https://myenpoint.com/invoice"
      },
      "authentication": {
        "basic": {
          "username": "test",
          "password": "myStrongPassword"
        }
      }
    }
  }
}
{
  "webhookId": "My webhook configuration with client credentials auth",
  "label": "My webhook configuration with client credentials auth",
  "adapterCode": "standardAdapter",
  "interopData": {
    "endpoints": {
      "status": {
        "callbackUrl": "https://myenpoint.com/status"
      },
      "invoice": {
        "callbackUrl": "https://myenpoint.com/invoice"
      },
      "authentication": {
        "oauth2password": {
          "callbackUrl": "https://myauthorizationServer.com/auth",
          "clientId": "myClientId",
          "username": "myUsername",
          "password": "myPassword"
        }
      }
    }
  }
}
{
  "webhookId": "My webhook configuration with client credentials auth",
  "label": "My webhook configuration with client credentials auth",
  "adapterCode": "standardAdapter",
  "interopData": {
    "endpoints": {
      "status": {
        "callbackUrl": "https://myenpoint.com/status"
      },
      "invoice": {
        "callbackUrl": "https://myenpoint.com/invoice"
      },
      "authentication": {
        "oauth2ClientCredentials": {
          "callbackUrl": "https://myauthorizationServer.com/auth",
          "clientId": "myClientId",
          "clientSecret": "myClientSecret"
        }
      }
    }
  }
}

Concept

filterStreamDirection

null : All received invoices and statuses are transmitted to this endpoint.
INBOUND : All received invoices, as well as the statuses related to a received invoice, are transmitted to this endpoint.
OUTBOUND : All statuses related to an issued invoice are transmitted to this endpoint.

Callback

Invoice

Invoice will be sent as multipart metadata with a property file

Status

Status will be sent in this format :

{
"invoiceId": "29d2576d-8408-4248-93b9-ca05251b4ce0",
"status": {
"code": "RECEIVED",
"value": "202",
"desc": "Reçue par la plateforme"
},
"xml": "<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<rsm:CrossDomainAcknowledgementAndResponse xmlns:qdt=\"urn:un:unece:uncefact:data:standard:QualifiedDataType:131\" ...",
"json": {
"category": {
"code": "eInvoicing",
"value": "S1"
},
"context": {
"id": "LC_RECEIVED_STREAM",
"name": "LifeCycle - Reçue par la plateforme",
"date": "2024-07-16T20:44:12Z",
"sender": {
"name": "SERARE",
"siren": "305836033",
"siret": "30583603300160",
"roleCode": {
"code": "BUYER",
"value": "BY",
"desc": "Acheteur"
}
},
"issuer": {
"name": "SERARE",
"siren": "305836033",
"siret": "30583603300160",
"roleCode": {
"code": "BUYER",
"value": "BY",
"desc": "Acheteur"
}
},
"recipients": [
{
"name": "CENTRE DE RHUMATOLOGIE DE L'ODYSSEUM DES DOCTEURS DIDY",
"siren": "325994648",
"siret": "32599464800039",
"roleCode": {
"code": "SUPPLIER",
"value": "SU",
"desc": "Fournisseur (B2B)"
}
}
]
},
"responses": [
{
"documentReference": {
"issuerAssignedId": "F-LTKAPRIdocgmdE",
"typeCode": 380,
"receiptDate": "2024-07-16T20:43:50Z",
"issuerTradeParty": {
"name": "CENTRE DE RHUMATOLOGIE DE L'ODYSSEUM DES DOCTEURS DIDY",
"siren": "325994648",
"siret": "32599464800039",
"roleCode": {
"code": "SUPPLIER",
"value": "SU",
"desc": "Fournisseur (B2B)"
}
}
},
"documentStatus": {
"status": {
"code": "RECEIVED",
"value": "202",
"desc": "Reçue par la plateforme"
},
"details": {
"generatedDate": "2024-07-16T20:44:12Z"
}
}
}
]
}
}