Background supergraphic

Buku Pemilik Kendaraan Bermotor (BPKB)

Buku Pemilik Kendaraan Bermotor (BPKB).

BPKB Object

  • Name
    status
    Type
    string
    Description

    Enum code indicating the status of the reading result.

    1. SUCCESS
    2. NO_FILE
    3. FILE_INVALID_FORMAT
    4. FAILED
  • Name
    reason
    Type
    string
    Description

    A human-readable message providing more details about the reading result.

  • Name
    read
    Type
    object
    Description

    Contains the reading for each BPKB fields. Each field contains:

    • confidence (number): Overall confidence score in percentage
    • value (string): The processed/extracted value
    • value_original (string): The original text as read from the document
    • confidence_text (number): Text recognition confidence in percentage
    • polygon (array): Array of coordinate pairs [x, y] representing the bounding box of the field
    • page_index (number): Page number where the field was found (0-indexed)
    • Name
      identitas_pemilik
      Type
      object
      Description
      • Name
        alamat
        Type
        object
        Description

        Address.

      • Name
        alamat_email
        Type
        object
        Description

        Email address.

      • Name
        dikeluarkan
        Type
        object
        Description

        Issued at.

      • Name
        nama_pemilik
        Type
        object
        Description

        Owner's name.

      • Name
        nomor_bpkb
        Type
        object
        Description

        BPKB number.

      • Name
        no_ktp_tdp
        Type
        object
        Description

        KTP number.

      • Name
        no_telepon
        Type
        object
        Description

        Phone number.

      • Name
        pada_tanggal
        Type
        object
        Description

        Issued date in dd-mm-yyyy format.

      • Name
        pekerjaan
        Type
        object
        Description

        Job.

      • Name
        stempel_nomor_bpkb
        Type
        object
        Description

        BPKB number stamp.

    • Name
      identitas_kendaraan
      Type
      object
      Description
      • Name
        bahan_bakar
        Type
        object
        Description

        Fuel type.

      • Name
        isi_silinder
        Type
        object
        Description

        Cylinder type.

      • Name
        jenis
        Type
        object
        Description

        Type.

      • Name
        jumlah_roda
        Type
        object
        Description

        Tyres count.

      • Name
        jumlah_sumbu
        Type
        object
        Description

        Axis count.

      • Name
        merk
        Type
        object
        Description

        Brand name.

      • Name
        model
        Type
        object
        Description

        Model.

      • Name
        nomor_mesin
        Type
        object
        Description

        Machine's number.

      • Name
        nomor_rangka
        Type
        object
        Description

        Skeleton number.

      • Name
        nomor_registrasi
        Type
        object
        Description

        Registration number.

      • Name
        tahun_pembuatan
        Type
        object
        Description

        Manufacturing year.

      • Name
        type
        Type
        object
        Description

        Type.

      • Name
        warna
        Type
        object
        Description

        Color.

      • Name
        warna_tnkb
        Type
        object
        Description

        Plate Color.

    • Name
      dokumen_registrasi_pertama
      Type
      object
      Description
      • Name
        nama_apm
        Type
        object
        Description

        APM name.

      • Name
        nomor_faktur
        Type
        object
        Description

        Invoice's number.

      • Name
        nomor_form_abc
        Type
        object
        Description

        ABC form's number.

      • Name
        tanggal_faktur
        Type
        object
        Description

        Invoice's date in dd-mm-yyyy format.

    • Name
      halaman_terakhir
      Type
      object
      Description
      • Name
        diterbitkan_oleh
        Type
        object
        Description

        Issued by.

      • Name
        no_register
        Type
        object
        Description

        Register's number.


POST/ocr/v1/bpkb

Read BPKB

Detects a valid BPKB image and returns the information as text.

Required parameter

  • Name
    image
    Type
    file (.png, .jpg, .jpeg, .tiff, .pdf)
    Description

    The image file for the BPKB.

Optional parameter

  • Name
    page
    Type
    number (1-4)
    Description

    If you only require a specific page number (1-4) of the BPKB, please include this parameter. If you need all pages, you can omit this parameter.

Sample Request

POST
/ocr/v1/bpkb
1
2
3
4
5
import { Vision } from '@glair/vision'; const vision = new Vision({ apiKey: 'api-key', username: 'username', password: 'password' }); await vision.ocr.bpkb({ image: '/path/to/image/BPKB.jpg' });

Sample Response

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
{ "status": "SUCCESS", "reason": "File Successfully Read", "read": { "dokumen_registrasi_pertama": { "nama_apm": { "value": "PT ISUZU ASTRA MOTOR INDONESIA", "value_original": "PT ISUZU ASTRA MOTOR INDONESIA", "confidence": 84.31, "confidence_text": 99.74, "polygon": [ [539, 517], [1047, 517], [1047, 559], [539, 559] ], "page_index": 2 }, "nomor_faktur": { "value": "1053-0002413379-24", "value_original": "1053-0002413379-24", "confidence": 92.71, "confidence_text": 97.51, "polygon": [ [542, 620], [824, 620], [824, 656], [542, 656] ], "page_index": 2 }, "tanggal_faktur": { "value": "11-06-2024", "value_original": "11 JUNI 2024", "confidence": 90.09, "confidence_text": 98.14, "polygon": [ [542, 657], [717, 657], [717, 691], [542, 691] ], "page_index": 2 }, "nomor_form_abc": { "value": "", "value_original": "", "confidence": 0, "confidence_text": 0, "polygon": [], "page_index": 0 } }, "halaman_terakhir": { "diterbitkan_oleh": { "value": "SATLANTAS POLRES TEGAL KOTA", "value_original": "SATLANTAS POLRES TEGAL KOTA", "confidence": 86.09, "confidence_text": 99.92, "polygon": [ [390, 613], [851, 613], [851, 652], [390, 652] ], "page_index": 3 }, "no_register": { "value": "R/003077/VI/2024/LL.TGL", "value_original": "R/003077/VI/2024/LL.TGL", "confidence": 88.63, "confidence_text": 99.26, "polygon": [ [399, 680], [822, 680], [822, 724], [399, 724] ], "page_index": 3 } }, "identitas_kendaraan": { "bahan_bakar": { "value": "SOLAR", "value_original": "SOLAR", "confidence": 91.27, "confidence_text": 99.99, "polygon": [ [1803, 633], [1903, 633], [1903, 668], [1803, 668] ], "page_index": 1 }, "isi_silinder": { "value": "2.499 CC", "value_original": "2.499 CC", "confidence": 90.54, "confidence_text": 99.87, "polygon": [ [496, 612], [623, 612], [623, 645], [496, 645] ], "page_index": 1 }, "jenis": { "value": "MB. BARANG", "value_original": "MB. BARANG", "confidence": 91.29, "confidence_text": 94.93, "polygon": [ [492, 425], [665, 425], [665, 467], [492, 467] ], "page_index": 1 }, "jumlah_roda": { "value": "4 (EMPAT)", "value_original": "4( EMPAT )", "confidence": 90.53, "confidence_text": 94.97, "polygon": [ [1801, 747], [1964, 747], [1964, 780], [1801, 780] ], "page_index": 1 }, "jumlah_sumbu": { "value": "2 (DUA)", "value_original": "2 ( DUA)", "confidence": 91.36, "confidence_text": 91.76, "polygon": [ [1801, 718], [1801, 682], [1920, 682], [1920, 718] ], "page_index": 1 }, "merk": { "value": "ISUZU", "value_original": "ISUZU", "confidence": 91.15, "confidence_text": 98.59, "polygon": [ [492, 296], [573, 296], [573, 333], [492, 333] ], "page_index": 1 }, "model": { "value": "PICK UP BOX", "value_original": "PICK UP BOX", "confidence": 93.29, "confidence_text": 98.44, "polygon": [ [492, 491], [679, 491], [679, 533], [492, 533] ], "page_index": 1 }, "nomor_mesin": { "value": "E540957", "value_original": "E540957", "confidence": 92.89, "confidence_text": 95.4, "polygon": [ [1543, 409], [1543, 382], [1653, 382], [1653, 409] ], "page_index": 1 }, "nomor_rangka": { "value": "MHCPHR54CRJ540957", "value_original": "MHCPHR54CRJ540957", "confidence": 89.62, "confidence_text": 97.82, "polygon": [ [1801, 250], [2107, 250], [2107, 285], [1801, 285] ], "page_index": 1 }, "nomor_registrasi": { "value": "G 8572 EE", "value_original": "G 8572 EE", "confidence": 92.42, "confidence_text": 97.98, "polygon": [ [490, 179], [682, 179], [682, 225], [490, 225] ], "page_index": 1 }, "tahun_pembuatan": { "value": "2024", "value_original": "2024", "confidence": 92.63, "confidence_text": 99.96, "polygon": [ [495, 545], [570, 545], [570, 584], [495, 584] ], "page_index": 1 }, "type": { "value": "PHR54U - CAAIN1 (4X2) M/T", "value_original": "PHR54U - CAAIN1 (4X2) M/T", "confidence": 92.43, "confidence_text": 96.77, "polygon": [ [491, 356], [862, 356], [862, 399], [491, 399] ], "page_index": 1 }, "warna": { "value": "PUTIH SILVER", "value_original": "PUTIH SILVER", "confidence": 97.25, "confidence_text": 99.68, "polygon": [ [1800, 200], [1994, 200], [1994, 236], [1800, 236] ], "page_index": 1 }, "warna_tnkb": { "value": "PUTIH", "value_original": "PUTIH", "confidence": 91.08, "confidence_text": 99.37, "polygon": [ [492, 245], [582, 245], [582, 282], [492, 282] ], "page_index": 1 } }, "identitas_pemilik": { "alamat": { "value": "JL. MASJID NO 30 KEL. MANGKUKUSUMAN KEC. TEGAL TIMUR KOTA TEGAL", "value_original": "JL. MASJID NO 30 KEL. MANGKUKUSUMAN KEC. TEGAL TIMUR KOTA TEGAL", "confidence": 94.05, "confidence_text": 99.43, "polygon": [ [427, 325], [1082, 325], [1082, 401], [427, 401] ], "page_index": 0 }, "alamat_email": { "value": "", "value_original": "-", "confidence": 59.74, "confidence_text": 99.27, "polygon": [ [429, 453], [448, 453], [448, 466], [429, 466] ], "page_index": 0 }, "dikeluarkan": { "value": "TEGAL", "value_original": "TEGAL", "confidence": 91.93, "confidence_text": 99.99, "polygon": [ [797, 526], [884, 526], [884, 561], [797, 561] ], "page_index": 0 }, "nama_pemilik": { "value": "CV. SAHABAT ANUGERAH SEJAHTERA", "value_original": "CV. SAHABAT ANUGERAH SEJAHTERA", "confidence": 92.1, "confidence_text": 96.35, "polygon": [ [430, 190], [1016, 190], [1016, 235], [430, 235] ], "page_index": 0 }, "no_ktp_tdp": { "value": "S120112190871", "value_original": "S120112190871", "confidence": 95.86, "confidence_text": 96.76, "polygon": [ [432, 256], [628, 256], [628, 290], [432, 290] ], "page_index": 0 }, "no_telepon": { "value": "", "value_original": "", "confidence": 47.07, "confidence_text": 0, "polygon": [ [430, 487], [447, 487], [447, 496], [430, 496] ], "page_index": 0 }, "nomor_bpkb": { "value": "U-03870835", "value_original": "U-03870835", "confidence": 95.95, "confidence_text": 99.98, "polygon": [ [1005, 100], [1005, 57], [1253, 57], [1253, 100] ], "page_index": 0 }, "pada_tanggal": { "value": "19-06-2024", "value_original": "19 JUNI 2024", "confidence": 91.74, "confidence_text": 98.99, "polygon": [ [796, 572], [971, 572], [971, 608], [796, 608] ], "page_index": 0 }, "pekerjaan": { "value": "", "value_original": "", "confidence": 0, "confidence_text": 0, "polygon": [], "page_index": 0 }, "stempel_nomor_bpkb": { "value": "", "value_original": "", "confidence": 0, "confidence_text": 0, "polygon": [], "page_index": 0 } } } }

Request ID

An associated request identifier is generated for every request made to this endpoint. This value can be found in the response headers under Request-Id


Responses

Various responses for this endpoint, in addition to general responses specified in Errors.

200 - OK

Request without parameter page

Response

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{ "status": "SUCCESS", "reason": "File Successfully Read", "read": { "identitas_pemilik": { //... }, "identitas_kendaraan": { //... }, "dokumen_registrasi_pertama": { //... }, "halaman_terakhir": { // ... } } }

200 - OK

Request with parameter page=1

Response

1
2
3
4
5
6
7
8
9
{ "status": "SUCCESS", "reason": "File Successfully Read", "read": { "identitas_pemilik": { //... } } }

200 - OK

Request with parameter page=2

Response

1
2
3
4
5
6
7
8
9
{ "status": "SUCCESS", "reason": "File Successfully Read", "read": { "identitas_kendaraan": { //... } } }

200 - OK

Request with parameter page=3

Response

1
2
3
4
5
6
7
8
9
{ "status": "SUCCESS", "reason": "File Successfully Read", "read": { "dokumen_registrasi_pertama": { //... } } }

200 - OK

Request with parameter page=4

Response

1
2
3
4
5
6
7
8
9
{ "status": "SUCCESS", "reason": "File Successfully Read", "read": { "halaman_terakhir": { // ... } } }

200 - OK

Request with non BPKB image

Response

1
2
3
4
5
{ "status": "SUCCESS", "reason": "File successfully read. Some fields are invalid.", //..., }

400 - Bad Request

Request without form-data image

Response

1
2
3
4
5
{ "status": "NO_FILE", "reason": "No file in request body", //..., }

415 - Unsupported Media Type

Request with non-image file format

Response

1
2
3
4
5
{ "status": "FILE_INVALID_FORMAT", "reason": "Failed to process invalid file format. Please upload the correct file format", //..., }