Fraud Prevention API

Version 1

The Fraud Prevention API is a set of APIs supporting Fraud detection including managing own fraud rules.

OpenAPI-Spezifikation herunterladen

List custom fraud rules

gethttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/:product

Authentifizierung

SchlüsselBeschreibungWoBeispiel
Authorization

Base64-kodierter API-Schlüssel und Geheimnis, verbunden durch einen Doppelpunkt.
Mehr lesen

Headers

Basic <base64>

Pfad Parameter

product
string
Erforderlich
Muss eines der folgenden sein:SMSVOICE

Abfrage Parameter

page_size
integer(int32)
Standard100

Page size in Integer format

page
integer(int32)
Standard1

Page number in Integer format

threshold
integer(int32)

Threshold value in Integer format

interval
integer(int32)

Interval value in Integer format it will be presented in minutes

countries
array

Array of ISO countries codes

Antworten
Inhalt Typ
application/json

OK

page
integer(int32)
page_size
integer(int32)
total_pages
integer(int32)
total_items
integer(int32)
_embedded
object
entries
array
country
string
interval
integer(int32)
threshold
integer(int32)
product
string
id
string
_links
object
self
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779

self link

_links
object
first
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=0&size=100

first link of the paginated result set

last
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=4&size=100

last link of the paginated result set

prev
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=0&size=100

previous link of the paginated result set

self
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=0&size=100

Beispiel Antwort

{
   "page": 0,
   "page_size": 0,
   "total_pages": 0,
   "total_items": 0,
   "_embedded": {
      "entries": [
         {
            "country": "string",
            "interval": 0,
            "threshold": 0,
            "product": "string",
            "id": "string",
            "_links": {
               "self": {
                  "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779"
               }
            }
         }
      ]
   },
   "_links": {
      "first": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=0&size=100"
      },
      "last": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=4&size=100"
      },
      "prev": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=0&size=100"
      },
      "self": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS?page=0&size=100"
      }
   }
}

Edit custom fraud rule by ID

puthttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/:id

Authentifizierung

SchlüsselBeschreibungWoBeispiel
Authorization

Base64-kodierter API-Schlüssel und Geheimnis, verbunden durch einen Doppelpunkt.
Mehr lesen

Headers

Basic <base64>

Pfad Parameter

Anfrage Körper
Inhalt Typ
application/json

product

Product type (SMS or VOICE)

country
string

ISO country code

interval
integer(int32)

Interval in minutes. Supported values:

  • 1 min: 1
  • 5 min: 5
  • 10 min: 10
  • 15 min: 15
  • 30 min: 30
  • 45 min: 45
  • 1 hour: 60
  • 6 hour: 360
  • 12 hour: 720
  • One day: 1440
Muss eines der folgenden sein:1510153045603607201440
threshold
integer(int32)

Beispiel Anfrage

{
   "product": null,
   "country": "string",
   "interval": 1,
   "threshold": 0
}

Antworten
Inhalt Typ
application/json

OK

country
string
interval
integer(int32)
threshold
integer(int32)
product
string
id
string
_links
object
self
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779

self link

Beispiel Antwort

{
   "country": "string",
   "interval": 0,
   "threshold": 0,
   "product": "string",
   "id": "string",
   "_links": {
      "self": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779"
      }
   }
}

Create custom fraud rule

posthttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules

Authentifizierung

SchlüsselBeschreibungWoBeispiel
Authorization

Base64-kodierter API-Schlüssel und Geheimnis, verbunden durch einen Doppelpunkt.
Mehr lesen

Headers

Basic <base64>

Anfrage Körper
Inhalt Typ
application/json

product

Product type (SMS or VOICE)

country
string

ISO country code

interval
integer(int32)

Interval in minutes. Supported values:

  • 1 min: 1
  • 5 min: 5
  • 10 min: 10
  • 15 min: 15
  • 30 min: 30
  • 45 min: 45
  • 1 hour: 60
  • 6 hour: 360
  • 12 hour: 720
  • One day: 1440
Muss eines der folgenden sein:1510153045603607201440
threshold
integer(int32)

Beispiel Anfrage

{
   "product": null,
   "country": "string",
   "interval": 1,
   "threshold": 0
}

Antworten
Inhalt Typ
application/json

Created

country
string
interval
integer(int32)
threshold
integer(int32)
product
string
id
string
_links
object
self
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779

self link

Beispiel Antwort

{
   "country": "string",
   "interval": 0,
   "threshold": 0,
   "product": "string",
   "id": "string",
   "_links": {
      "self": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779"
      }
   }
}

Get custom fraud rule by product and id

gethttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/:product/:id

Authentifizierung

SchlüsselBeschreibungWoBeispiel
Authorization

Base64-kodierter API-Schlüssel und Geheimnis, verbunden durch einen Doppelpunkt.
Mehr lesen

Headers

Basic <base64>

Pfad Parameter

product
string
Erforderlich
Muss eines der folgenden sein:SMSVOICE
id
string
Erforderlich

Rule ID in UUID format

Antworten
Inhalt Typ
application/json

OK

country
string
interval
integer(int32)
threshold
integer(int32)
product
string
id
string
_links
object
self
object
href
string
Beispielhttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779

self link

Beispiel Antwort

{
   "country": "string",
   "interval": 0,
   "threshold": 0,
   "product": "string",
   "id": "string",
   "_links": {
      "self": {
         "href": "https://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/SMS/e21ace94-54fa-4365-a824-38033dc06779"
      }
   }
}

Delete custom fraud rule by ID

deletehttps://api.nexmo.com/v1/fraud-defender/configuration/custom-rules/:product/:id

Authentifizierung

SchlüsselBeschreibungWoBeispiel
Authorization

Base64-kodierter API-Schlüssel und Geheimnis, verbunden durch einen Doppelpunkt.
Mehr lesen

Headers

Basic <base64>

Pfad Parameter

product
string
Erforderlich
Muss eines der folgenden sein:SMSVOICE
id
string
Erforderlich

Rule ID in UUID format

Antworten

No Content

Fehler

Im Folgenden finden Sie eine nicht erschöpfende Liste von Fehlercodes, die bei der Verwendung dieser API auftreten können.

Diese Codes gelten zusätzlich zu unseren generische Fehlercodes.

CodeInformationen
http:error:conflict

Rule couldn't be added as conflicts with currently existing rules

system:error:internal-error

Something went wrong.