Memulai
Kredensial diberikan tim TAXLINK setelah permintaan akses disetujui di konsol admin. Setiap request memakai HTTP Basic Auth dan header npwp berisi NPWP organisasi yang sedang bertindak. NPWP harus terdaftar pada kredensial; jika tidak, API membalas 403.
| Staging lokal | http://localhost:4000 |
|---|---|
| Autentikasi | Authorization: Basic base64(username:password) |
| Header wajib | npwp: 0123456789012000 |
curl -X POST http://localhost:4000/v2/vswp \
-u demo:taxlink-demo \
-H "npwp: 0123456789012000" \
-H "Content-Type: application/json" \
-d '{"npwp":"3201234567890000","tujuan":"Validasi NPWP"}'Konvensi API
Setiap response JSON memakai envelope yang sama:
{
"status_code": 200,
"message": "OK",
"data": {
"status": "1", // "1" sukses, "0" gagal bisnis di DJP
"statusMessage": "Success",
"result": { ... }, // hanya ada bila status "1"
"uuid": "9fc2be05-..." // ID korelasi, cari di /v1/histories
}
}- Soft-error: penolakan DJP (WP tidak ditemukan, periode salah, dst.) tetap HTTP 200 dengan
data.status = "0". Kode 4xx/5xx hanya untuk galat transport. - Kode HTTP: 400 validasi, 401 kredensial, 402 kuota habis, 403 NPWP tidak terdaftar, 5xx boleh di-retry dengan backoff.
- Format: tanggal dokumen
DDMMYYYY; masa pajakMM; masa SPTMMMM; periode billingMMMMYYYY; tarif PPN pecahan (0.12), tarif PPh persen (7.5). - Field sensitif:
passphrasePenandatangan,passphrase, danpasswordtidak pernah disimpan; di riwayat ditampilkan sebagai[REDACTED]. - Biaya: endpoint bertanda ● dihitung Rp1.000 per sukses bisnis dan mengurangi kuota prabayar.
Organization
Profil klien, pemakaian kuota, riwayat panggilan, dan pendaftaran NPWP tambahan.
| Method | Path | Fungsi | Biaya |
|---|---|---|---|
| GET | /v1/profile | Profil organisasi untuk NPWP aktif | |
| POST | /v1/profile | Ubah sebagian field profil | |
| GET | /v1/usage | Ringkasan pemakaian dan biaya per periode | |
| GET | /v1/histories | Riwayat panggilan API (field sensitif disamarkan) | |
| POST | /v1/organization | Daftarkan NPWP tambahan ke kredensial |
VSWP — Validasi Status Wajib Pajak
Cek NPWP/NIK tunggal secara real-time (cache 90 hari) atau massal lewat job CSV.
| Method | Path | Fungsi | Biaya |
|---|---|---|---|
| POST | /v2/vswp | Validasi satu NPWP/NIK | ● |
| POST | /v1/vswp/bulking | Kirim CSV untuk validasi massal | |
| GET | /v1/vswp/{id} | Status job massal | |
| GET | /v1/vswp/{id}/export | Unduh hasil job (CSV) |
e-Faktur
Terbitkan, ganti, dan batalkan faktur pajak keluaran. PPN dihitung ulang di server.
| Method | Path | Fungsi | Biaya |
|---|---|---|---|
| GET | /v1/ref/{catalogue} | Katalog referensi (negara, satuan, kode transaksi, ...) | |
| GET | /v1/efaktur | Daftar faktur milik NPWP aktif | |
| POST | /v2/efaktur/create-faktur-pk | Terbitkan faktur keluaran | ● |
| POST | /v2/efaktur/create-faktur-pk-amended | Terbitkan faktur pengganti | ● |
| POST | /v2/efaktur/cancel-faktur-pk | Batalkan faktur |
e-Bupot
Bukti potong PPh Unifikasi (BPPU) dan PPh 21 bukan pegawai (BPMP), plus kalkulator lokal.
| Method | Path | Fungsi | Biaya |
|---|---|---|---|
| GET | /v1/ebupot | Daftar bukti potong | |
| POST | /v2/ebupot/validate-bpu-a0-21 | Validasi dan hitung tanpa menerbitkan | |
| POST | /v2/ebupot/create-bpu-a0-21 | Terbitkan bukti potong | ● |
| POST | /v2/ebupot/cancel-bpu-a0-21 | Batalkan bukti potong | |
| POST | /calculation | Kalkulator PPh (tanpa autentikasi) |
SPT
Lapor SPT bertahap: cek periode, buat, unggah isi, kirim, lalu verifikasi sampai BPE terbit.
| Method | Path | Fungsi | Biaya |
|---|---|---|---|
| GET | /v1/spt | Daftar SPT | |
| POST | /v2/spt/inquiry-max-rev-no | Cek revisi terakhir untuk periode | |
| POST | /v2/spt/create-spt | Buat SPT (normal atau pembetulan) | ● |
| POST | /v2/spt/inquiry-spt | Status SPT | |
| POST | /v2/spt/upload | Unggah isi SPT | |
| POST | /v2/spt/submit-spt | Kirim SPT ke DJP, terima NTTE | |
| POST | /v2/spt/verify-spt | Verifikasi dan ambil nomor BPE |
e-Billing
Inquiry KAP/KJS lalu terbitkan ID Billing 15 digit yang berlaku 14 hari.
| Method | Path | Fungsi | Biaya |
|---|---|---|---|
| GET | /v1/ebilling | Daftar ID Billing | |
| POST | /v2/ebilling/inquiry | Cek NPWP + KAP/KJS | |
| POST | /v2/ebilling/create | Terbitkan ID Billing | ● |