Download the PHP package tidycode/ai-php-sdk without Composer
On this page you can find all versions of the php package tidycode/ai-php-sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download tidycode/ai-php-sdk
More information about tidycode/ai-php-sdk
Files in tidycode/ai-php-sdk
Package ai-php-sdk
Short Description Tidycode AI PHP SDK is a PHP API client that allows you to integrate artificial intelligence services deployed by Tidycode.
License MIT
Informations about the package ai-php-sdk
SDK Tidycode AIClient for PHP.
This SDK allows you to integrate your PHP eCommerce with our dedicated artificial intelligence services. Currently, the SDK supports the Fraud Detection service, but is designed to be extended with other services in the future.
Installation.
To use this SDK, you must add it to your PHP project. It can be installed via Composer.
Add the dependency to the composer.json
of your composer module or package:
or install it via the composer command
Then run the command:
Using Fraud Detection
Configuration.
To start using the Fraud Detection service, create an instance of the Tidycode\AIClient\FraudDetection
class.
Methods
The SDK offers the following methods:
1. detectFraud
.
Checks whether an order is suspected of fraud.
Parameters: a JSON array with the order data.
JSON format:
Example usage:
2. reportFalsePositive
.
Reports an incorrectly classified order as fraud.
Parameters: a JSON array with the order data. The JSON is the same as the detectFraud
method.
Example usage:
3. reportFalseNegative
.
Reports an order incorrectly classified as non-fraudulent. The JSON is the same as in the detectFraud
method.
Parameters: a JSON array with the order data.
Example usage:
4. paymentList
.
Returns the list of payment method codes.
Example usage:
5. shipmentList
.
Returns the list of shipment method codes.
Example usage:
Adding New Services.
The SDK is designed to be extended with additional services in the future. Any new services will be documented and added to the list of available methods in this README.
License.
This project is licensed under the MIT License.
SDK Tidycode AIClient per PHP
Questo SDK consente di integrare i vostri eCommerce PHP con i nostri servizi di intelligenza artificiale dedicati. Attualmente, il SDK supporta il servizio di Rilevamento Frodi, ma è progettato per essere esteso con altri servizi in futuro.
Installazione
Per utilizzare questo SDK, è necessario aggiungerlo al vostro progetto PHP. Può essere installato tramite Composer.
Aggiungi la dipendenza al composer.json
del tuo modulo o pacchetto composer:
oppure installalo tramite il comando composer
Esegui quindi il comando:
Utilizzo Fraud Detection
Configurazione
Per iniziare a utilizzare il servizio di Fraud Detection, crea un'istanza della classe Tidycode\AIClient\FraudDetection
.
Metodi
L'SDK offre i seguenti metodi:
1. detectFraud
Verifica se un ordine è sospetto di frode.
Parametri: un array JSON con i dati dell'ordine.
Formato JSON:
Esempio di utilizzo:
2. reportFalsePositive
Segnala un ordine erroneamente classificato come frode.
Parametri: un array JSON con i dati dell'ordine. Il JSON è il medesimo del metodo detectFraud
Esempio di utilizzo:
3. reportFalseNegative
Segnala un ordine erroneamente classificato come non fraudolento. Il JSON è il medesimo del metodo detectFraud
Parametri: un array JSON con i dati dell'ordine.
Esempio di utilizzo:
4. paymentList
Restituisce la lista dei codici dei metodi di pagamento.
Esempio di utilizzo:
5. shipmentList
Restituisce la lista dei codici dei metodi di spedizione.
Esempio di utilizzo:
Aggiunta Nuovi Servizi
Il SDK è progettato per essere esteso con ulteriori servizi in futuro. Ogni nuovo servizio sarà documentato e aggiunto alla lista dei metodi disponibili in questo README.
Licenza
Questo progetto è concesso in licenza sotto la Licenza MIT.