Langsung ke konten utama
POST
Tambah perangkat baru

Otorisasi

Authorization
string
header
wajib

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Body

application/json
device_id
string

ID perangkat kustom opsional. Jika tidak diberikan, ID akan dibuat secara otomatis.

Contoh:

"my-custom-device-id"

webhook_url
string

URL webhook khusus perangkat yang opsional. Jika disetel, event untuk perangkat ini akan dikirim ke sini sebagai pengganti webhook global.

Contoh:

"https://device-webhook.example.com/handler"

webhook_secret
string

Secret opsional yang digunakan untuk menandatangani payload webhook khusus perangkat (HMAC).

Contoh:

"super-secret-key"

webhook_events
string

Daftar nama event opsional yang dipisahkan koma untuk diteruskan ke webhook khusus perangkat. Kosong berarti semua event.

Contoh:

"message,message.ack"

webhook_insecure_skip_verify
boolean

Opsional. Lewati verifikasi sertifikat TLS saat mengirim ke webhook khusus perangkat.

Contoh:

false

Respons

OK

code
string
Contoh:

"SUCCESS"

message
string
Contoh:

"Device added"

status
integer
Contoh:

200

results
object