9.0 KiB
SoluTax Bruno API Collection - Agents Documentation
Project Overview
This is a Bruno API collection for testing and interacting with the SoluTax IFS WIT API developed by PT Sarana Prima Telematika. The collection provides integration capabilities with Indonesia's tax system (DJP - Direktorat Jenderal Pajak) for electronic withholding tax slips (Bukti Potong).
Purpose
The API collection enables management of electronic tax withholding slips for Indonesian payroll and tax compliance:
- PPh 21 - Employee income tax withholding (monthly/non-final)
- PPh A0 - Permanent employee monthly withholding
- PPh A1 - Permanent employee annual withholding
Technologies Used
- Bruno - Git-friendly, offline-first API client
- Bru - Plain text markup language for API requests
- Node.js - Minimal project structure (package-lock.json present)
Project Structure
solutax/
├── bruno.json # Bruno collection configuration
├── agents.md # This file - AI agent documentation
├── QWEN.md # Project overview and context
├── spesifikasi.md # Full API specification document (Indonesian)
├── token.bru # Authentication token request
├── ppha0-new.bru # PPh A0 - Pengesahan (Create)
├── ppha0-edit.bru # PPh A0 - Penggantian (Replace)
├── ppha0-cancel.bru # PPh A0 - Pembatalan (Cancel)
├── ppha0-status.bru # PPh A0 - Periksa Status (Check)
├── ppha0-pdf.bru # PPh A0 - Unduh PDF (Download)
├── test.bru # Test request file
├── package-lock.json # Node.js lock file
├── environments/
│ ├── solutax.bru # Development environment variables
│ └── solutax.json # Environment configuration
└── sample result/
├── ppha0_new_result_sample.json
└── token_result_sample.json
API Endpoints Summary
1. Token Authentication
| Endpoint | Method | Description |
|---|---|---|
/auth/gettoken |
POST | Get JWT access token using Basic Auth |
Security: Basic Authentication (username/password)
2. PPh 21 Withholding Slips (Monthly/Non-Final)
| Endpoint | Method | Description |
|---|---|---|
/ifs/api/wit/bulanan/new |
POST | Create and approve new PPh 21 slip |
/ifs/api/wit/bulanan/edit |
POST | Replace/modify existing PPh 21 slip |
/ifs/api/wit/cancel |
POST | Cancel a PPh 21 slip |
/ifs/api/wit/status |
POST | Check status of PPh 21 slip |
/ifs/api/wit/pdf |
POST | Download PDF of PPh 21 slip |
3. PPh A0 Withholding Slips (Permanent Employee Monthly)
| Endpoint | Method | Description |
|---|---|---|
/ifs/api/wit/bulanan/new |
POST | Create and approve new PPh A0 slip |
/ifs/api/wit/bulanan/edit |
POST | Replace/modify existing PPh A0 slip |
/ifs/api/wit/cancel |
POST | Cancel a PPh A0 slip |
/ifs/api/wit/status |
POST | Check status of PPh A0 slip |
/ifs/api/wit/pdf |
POST | Download PDF of PPh A0 slip |
4. PPh A1 Withholding Slips (Permanent Employee Annual)
| Endpoint | Method | Description |
|---|---|---|
/ifs/api/wit/tahunan/new |
POST | Create and approve new PPh A1 slip |
/ifs/api/wit/tahunan/edit |
POST | Replace/modify existing PPh A1 slip |
/ifs/api/wit/cancel |
POST | Cancel a PPh A1 slip |
/ifs/api/wit/status |
POST | Check status of PPh A1 slip |
/ifs/api/wit/pdf |
POST | Download PDF of PPh A1 slip |
Agent Workflows
Workflow 1: Authentication and Token Management
Goal: Obtain and manage access tokens for API requests
- Get Token
- Execute
token.bru - Uses Basic Auth with credentials from
auth:basicblock - Response contains
access_token,idpel, andexpires_in - Token automatically set as
accessTokenenvironment variable - Customer ID set as
idpelenvironment variable
- Execute
Workflow 2: Create New Tax Slip (PPh A0 Example)
Goal: Create and approve a new withholding tax slip
- Execute ppha0-new.bru
- Generates new UUID for
requestID - Sends monthly income data with taxpayer information
- Includes
dataBpA0object with tax calculation details - Response extracts and stores
nomorBupotandidBupot
- Generates new UUID for
Workflow 3: Replace/Modify Existing Slip
Goal: Update an existing approved tax slip
- Execute ppha0-edit.bru
- Requires existing
nomorBupotandidBupot - Sends updated data with all required fields
- New approval number assigned upon success
- Requires existing
Workflow 4: Cancel Tax Slip
Goal: Cancel an approved tax slip
- Execute ppha0-cancel.bru
- Generates new UUID for
requestID - Requires
nomorBupotandidBupotto cancel - Includes
tglPembatalan(cancellation date) - Requires electronic signature credentials
- Generates new UUID for
Workflow 5: Check Slip Status
Goal: Verify status of a tax slip (after create, edit, or cancel)
- Execute ppha0-status.bru
- Queries
taxSlipVerificationobject - Returns status:
NORMAL-DONE,AMENDED, orCANCELLED-Done - Includes verification timestamp
- Queries
Workflow 6: Download PDF
Goal: Retrieve PDF document of approved tax slip
- Execute ppha0-pdf.bru
- Requires
nomorBupotandidBupot - Response contains
datafield with Base64-encoded PDF - File name typically matches
nomorBuktiPotong
- Requires
Key Concepts
Request Structure
All requests follow a consistent pattern:
| Field | Type | Description |
|---|---|---|
idPel |
Number | Customer ID (extracted from token response) |
requestID |
String (GUID) | Unique request identifier (auto-generated) |
monthlyIncome / yearlyIncome / taxSlip* |
Object | Endpoint-specific data payload |
Response Structure
All responses follow a consistent pattern:
| Field | Description |
|---|---|
kodestatus / statusCode |
HTTP status code (200 = success) |
keterangan / statusMessage |
Status description |
data / result / taxSlipResponse |
Response payload |
idPel / responseID |
Tracking identifiers |
Common Status Codes
| Code | Meaning |
|---|---|
| 200 | Success |
| 401 | Unauthorized (invalid/expired token) |
| 500 | Server error (e.g., invalid User ID) |
Slip Status Values
| Status | Meaning |
|---|---|
NORMAL-DONE |
Original slip approved |
AMENDED |
Slip was replaced/modified |
CANCELLED-Done |
Slip was cancelled |
Environment Variables
The following environment variables are used:
| Variable | Description | Source |
|---|---|---|
accessToken |
JWT authentication token | Token response |
idpel |
Customer ID | Token response |
requestID |
Unique request GUID | Auto-generated or env |
nomorBupot |
Tax slip number | New/Edit response |
idBupot |
Tax slip ID (UUID) | New/Edit response |
Configuration
Bruno Collection Config (bruno.json)
{
"version": "1",
"name": "solutax",
"type": "collection",
"ignore": ["node_modules", ".git", "QWEN.md", "spesifikasi.md"]
}
API Base URL
https://ifswit-solutax-ctas-dev.spt.co.id
Note: This is the development/ctas-dev environment.
Testing Workflow
Step-by-Step Process
-
Get Token
- Execute
token.brufirst - Verify
accessTokenis set in environment
- Execute
-
Create Slip
- Execute
ppha0-new.bru - Note the
nomorBupotandidBupotfrom response
- Execute
-
Verify Status
- Execute
ppha0-status.bru - Confirm
statusBupotisNORMAL-DONE
- Execute
-
Download PDF (optional)
- Execute
ppha0-pdf.bru - Decode Base64 data to PDF file
- Execute
-
Modify Slip (if needed)
- Execute
ppha0-edit.bru - Verify new
nomorBupotassigned
- Execute
-
Cancel Slip (if needed)
- Execute
ppha0-cancel.bru - Verify
statusBupotbecomesCANCELLED-Done
- Execute
Important Notes
-
Language: All API documentation and field names are in Indonesian (Bahasa Indonesia)
-
Environment: This is a development/DEV environment (CTAS-DEV)
-
Token Expiration: Monitor
expires_infield; tokens will expire and require renewal -
NPWP Validation: Tax ID numbers (NPWP) are validated on all endpoints
-
Electronic Signature: Passphrase required for penandatangan (signatory) on create/edit/cancel operations
-
Pre-request Scripts: Some files auto-generate UUIDs for
requestIDusing JavaScript -
Post-response Scripts: Some files extract and store response values as environment variables
Documentation References
- spesifikasi.md - Complete API specification (Indonesian)
- QWEN.md - Project overview and context
- Official Bruno Docs
- SoluTax API Specification - API base URL
Contact Information
Developer: PT Sarana Prima Telematika
Year: 2026
Version: 1.0