Ecommerce

Create Evaluation

Receives a new transaction for antifraud analysis, if used with pre-evaluation it should be called after the payment authorization. Its mandatory to reuse the reference_id from pre-evaluation.

post/v1/antifraud/evaluations

Request

  • Base URL
    https://api-sandbox.koin.com.br
  • URL
    https://api-sandbox.koin.com.br/v1/antifraud/evaluations
  • Auth
    none declared

Request body

type'Ecommerce' required

Antifraud type

service_datestring

Date which the service will take place

sla_datestring

The date that the evaluation is expected to be resolved

callback_urlstring

A publicly accessible HTTPS endpoint where your application will receive asynchronous notifications about the status of the evaluation.

Example request

{
  "buyer": {
    "id": "c1245228",
    "first_name": "Alvaro",
    "last_name": "Garrincha",
    "full_name": "Alvaro Garrincha",
    "document": {
      "nationality": "UY",
      "number": "35645888",
      "type": "DNI"
    },
    "address": {
      "city": "Buenos Aires",
      "complement": "Complemento",
      "country_code": "AR",
      "neighborhood": "Chacarita",
      "number": "2459",
      "state": "Buenos Aires",
      "street": "Corrientes",
      "zip_code": "1425",
      "full_address": "Corrientes 747, San Nicolas"
    },
    "birth_date": "1990-05-06",
    "email": "email@domain.com",
    "phone": {
      "area_code": "11",
      "number": "45669874",
      "type": "Mobile"
    },
    "profile": {
      "category": "Platinum",
      "points_balance": 1500
    }
  },
  "device": {
    "ipv4": "70.56.69.13",
    "ipv6": "2001:0db8:85a3:0000:0000:8a2e:0370:7334",
    "location": {
      "latitude": -34.56532789616039,
      "longitude": -58.48945822129388
    },
    "merchant_device": "234c20c3-45de-41bf-b243-87ad5$RTbc3b",
    "session_id": "5b8c20c3-45de-41bf-b243-87ad5d21bc3b"
  },
  "store": {
    "code": "Hellmans",
    "category": "0763",
    "latitude": -34.56532789616039,
    "longitude": -58.48945822129388,
    "merchant_type": "shopping",
    "name": "STORE NAME"
  },
  "items": [
    {
      "category": {
        "id": "111",
        "name": "Some category name"
      },
      "discount_amount": {
        "currency_code": "USD",
        "value": 8008.99
      },
      "id": "13238487",
      "name": "Some name",
      "price": {
        "currency_code": "USD",
        "value": 8008.99
      },
      "quantity": 5,
      "seller_id": "Some Seller",
      "service_date": "2021-10-23T10:00:00.307062Z",
      "type": "Generic"
    }
  ],
  "payments": [
    {
      "id": "02BF653185664752AA5F8B7415BD5043",
      "amount": {
        "currency_code": "USD",
        "value": 8008.99
      }
    }
  ],
  "shipping": {
    "address": {
      "city": "Buenos Aires",
      "complement": "Complemento",
      "country_code": "AR",
      "neighborhood": "Chacarita",
      "number": "2459",
      "state": "Buenos Aires",
      "street": "Corrientes",
      "zip_code": "1425",
      "full_address": "Corrientes 747, San Nicolas"
    },
    "delivery": {
      "by": "DHL",
      "date": "2021-02-23T14:10:44.307062Z",
      "type": "EXPRESS"
    },
    "price": {
      "currency_code": "USD",
      "value": 8008.99
    }
  },
  "transaction": {
    "reference_id": "FGCCCEA53JYSHXX",
    "business_id": "6LVHR8W0V7BYEQX",
    "sequence": "1",
    "country_code": "AR",
    "listener_mode": true,
    "total_amount": {
      "currency_code": "USD",
      "value": 8008.99
    },
    "origin": "API",
    "origin_id": "lnk_8f3a2c91"
  },
  "service_date": "2021-10-23T10:00:00.307062Z",
  "sla_date": "2021-07-23T16:00:00.307062Z",
  "callback_url": "http://domain/service",
  "client_info": {
    "creation_date": "1978-04-29T17:10:35.387Z",
    "classification": "GOLD",
    "customer_order": {
      "currency_code": "USD",
      "value": 8008.99
    },
    "days_since_first_order": 45,
    "days_since_last_order": 10,
    "cancelled_orders": 3,
    "average_order": {
      "currency_code": "USD",
      "value": 8008.99
    },
    "cash_orders": 3,
    "card_orders": 6,
    "bank_orders": 4,
    "debit_orders": 2,
    "super_segmentation": "potential",
    "purchase_power": "pph",
    "year_first_purchase": 2024,
    "purchases_30_days": 12,
    "purchases_60_days": 22,
    "purchases_lifetime": 32
  },
  "strategies_data": {
    "collect_auth_supported": true,
    "acquirer_bin": "408956",
    "acquirer": "WDP",
    "merchant_id": "BRLIARLEGAPR",
    "mcc": "1234",
    "merchant_descriptor": "DAGS_TEST_3DS"
  }
}

Response

Evaluation response

analysis_type'AUTOMATIC' | 'MANUAL'

Resolution type

evaluation_idstring

antifraud provider identifier

idstring

Client transaction identifier

scoreinteger

Evaluation score

status'approved' | 'denied' | 'received'

Transaction status

Changes

No recorded changes to this operation across all 1 revision of this API.