Supplier Data Model

Data Model

Overview

The "Supplier Data Model" is a Data model type used in your webhook endpoint. This model provides information about any SupplierStatusChanged event.

Your webhook endpoint will receive a POST request from MyFatooah that contains an EventType parameter with a value of "4". It is used to notify your system of the supplier account status (approved, rejected). Detailed functionality of how to implement your webhook endpoint is explained in the Webhook section.

Now, we are going to declare the Transaction Data Model properties of your endpoint and its models along with each accepted parameter and possible value.


Request Model

Input Parameter

Type

Description

SupplierCode

number

SupplierName

string

SupplierName

string

SupplierEmail

string

SupplierStatus

string

APPROVED
REJECTED


Sample Message

The below sample JSON message is sent by MyFatoorah to your endpoint.

{
   "EventType":4,
   "Event":"SupplierStatusChanged",
   "DateTime":"04032021212759",
   "CountryIsoCode":"KWT",
   "Data":{
      "SupplierCode":11,
      "SupplierName":"test webhok 10",
      "SupplierMobile":"123456",
      "SupplierEmail":"[email protected]",
      "SupplierStatus":"APPROVED"
   }
}

👍

Signature

To generate the signature of this model, you should order only the above parameters alphabetic with its values then encrypt it by the secret key.

The following will be a sample string used in generating the signature.

SupplierCode=11,[email protected],SupplierMobile=123456,SupplierName=test webhok 10,SupplierStatus=APPROVED


Did this page help you?