Project

General

Profile

Specification » History » Version 11

Soh Keong, 05/29/2024 12:39 PM

1 1 Soh Keong
{{toc}}
2
3
h1. Specification
4
5
h1. Programming Guide
6
7
h2. Jar version 
8
9
|_. version |_. Description                                |
10
| 1.0       | Init                                         |
11
12
h2. Jar File Download
13
14
"Jar":
15
"Properties":
16
17
h3. Classes
18
19
* *my.aisino.einvoice.bean* 
20
* *my.aisino.einvoice.bean.transaction* 
21
* *my.aisino.einvoice.constant* 
22
* *my.aisino.einvoice.service* 
23
* *my.aisino.einvoice.util* 
24
25
h3. properties file
26
27
* *service.properties*
28
29
# *merchant.id*       -
30
31
h2. Aisino Service
32
33
<pre>
34
my.aisino.einvoice.service.TransactionService service = new my.aisino.einvoice.service.TransactionService();
35
</pre>
36
37 8 Soh Keong
h3. submitEInvoice
38 1 Soh Keong
39
<pre>
40 7 Soh Keong
InvoiceSubmissionResponseBean responseBean = service.submitEInvoice(Connection conn, InvoiceSubmissionRequestBean bean);
41 1 Soh Keong
</pre>
42
43 10 Soh Keong
<pre>
44
CommonConstant = my.aisino.einvoice.constant.CommonConstant
45
</pre>
46
47 1 Soh Keong
# *conn*           - Database connection.
48
# *bean*           - Object.
49
> * *orderId*
50 10 Soh Keong
> * *orderDate*     - Format(yyyy-MM-dd)
51
> * *orderTime*     - Format(HH:mm:ssZ)
52 11 Soh Keong
> * *orderTypeCode* - CommonConstant.INVOICE_TYPE_CODE_* (https://sdk.myinvois.hasil.gov.my/codes/e-invoice-types/)
53 10 Soh Keong
> * *currencyCode*  - CommonConstant.CURRENCY_CODE_* (https://sdk.myinvois.hasil.gov.my/codes/currencies/)
54 1 Soh Keong
> * *totalExcludingTax* 
55
> * *totalIncludingTax* 
56
> * *totalPayableAmount* 
57
58 6 Soh Keong
> * *buyerBean* 
59
> ** *address* 
60 10 Soh Keong
> *** *country*  - CommonConstant.COUNTRY_* (https://sdk.myinvois.hasil.gov.my/codes/countries/)
61 11 Soh Keong
> *** *state*    - CommonConstant.STATE_* (https://sdk.myinvois.hasil.gov.my/codes/state-codes/)
62 10 Soh Keong
> *** *city*     - Max length : 50
63
> *** *address1* - Max length : 150
64
> *** *address2* - Max length : 150
65
> *** *address3* - Max length : 150
66
> ** *contactNumber* - Max length : 20
67
> ** *name*          - Max length : 300
68 8 Soh Keong
> ** *registrationList*
69
> *** *brn*      (Optional)
70
> *** *tin*      (Optional)
71
> *** *nric*     (Optional)
72
> *** *passport* (Optional)
73
> *** *army*     (Optional)
74 2 Soh Keong
> *** *sst*      (Optional)
75
76 6 Soh Keong
> * *productList*
77 11 Soh Keong
> ** *productName*        - Max length : 300
78
> ** *productCode*        - Max length :  18
79
> ** *measurement*        - CommonConstant.MEASUREMENT_* (https://sdk.myinvois.hasil.gov.my/codes/unit-types/)
80 6 Soh Keong
> ** *quantity*  (Optional) 
81
> ** *totalExcludingTax*
82
> ** *unitPrice*
83
> ** *subtotal*
84 11 Soh Keong
> ** *classificationList* 
85
> *** *code*              - CommonConstant.CLASSIFICATION_CODE_* (https://sdk.myinvois.hasil.gov.my/codes/classification-codes/)
86
> *** *group*             - CommonConstant.CLASSIFICATION_GROUP_* 
87 6 Soh Keong
> ** *taxTotalBean*
88
> *** *totalTaxAmount*
89
> *** *taxSubTotalList*
90 8 Soh Keong
> **** *taxType*
91
> **** *percent*          (Optional)
92
> **** *perUnitAmount*    (Optional)
93
> **** *baseUnitMeasure*  (Optional)
94 6 Soh Keong
> **** *netAmount*        (Optional)
95 3 Soh Keong
> **** *tax*
96
97 6 Soh Keong
> * *taxTotalBean*
98
> ** *totalTaxAmount*
99
> ** *taxSubTotalList*
100
> *** *taxType*
101
> *** *percent*
102
> *** *perUnitAmount*
103 1 Soh Keong
> *** *baseUnitMeasure*
104
> *** *netAmount*
105
> *** *tax*
106
107
  3. *responseBean*
108
109
> * *submissionUid*
110
> * *acceptedDocumentList*
111
> ** *orderId*
112
> ** *uuid*
113
> * *rejectedDocumentList*
114
> ** *orderId*
115
> ** *errorList*
116 4 Soh Keong
> *** *code*
117 8 Soh Keong
> *** *message*
118
119
120 10 Soh Keong
h3. queryEInvoice
121 8 Soh Keong
122
<pre>
123 10 Soh Keong
InvoiceInquiryResponseBean responseBean = service.queryEInvoice(Connection conn, InvoiceInquiryRequestBean bean);
124 8 Soh Keong
</pre>
125
126
# *conn*           - Database connection.
127 9 Soh Keong
# *bean*           - Object.
128
> * *documentNum*
129
> * *submissionUid*
130
> * *invoiceUuid*
131
> * *invoiceTypeCode*
132
> * *buyerTin*
133
> * *buyerName*
134
> * *totalAmountFrom*
135
> * *totalAmountTo*
136
> * *invoiceStatus*
137
> * *confirmStatusCode*
138
> * *issuedDateFrom*
139
> * *issuedDateTo*
140
> * *pageIndex* (Mandatory)
141
> * *pageSize* (Mandatory)
142
143
  3. *responseBean*
144
145
> * *page*
146
> ** *pageCount*
147
> ** *pageNo*
148
> ** *pageSize*
149
> ** *totalSize*
150
151
> * *recordList*
152
> ** *buyerTin*
153
> ** *confirmStatusCode*
154
> ** *currency*
155 1 Soh Keong
> ** *description*
156
> ** *documentNum*
157
> ** *excludingTaxAmount*
158
> ** *includingTaxAmount*
159
> ** *invoiceId*
160
> ** *invoiceStatus*
161
> ** *invoiceTypeCode*
162
> ** *invoiceUuid*
163
> ** *issuedDate*
164
> ** *nowTime*
165
> ** *operationDate*
166
> ** *operator*
167
> ** *pageIndex*
168
> ** *pageNo*
169
> ** *pageSize*
170
> ** *submissionUid*
171 9 Soh Keong
> ** *transactionId*
172 10 Soh Keong
173
h3. cancelEInvoice
174
175
<pre>
176
InvoiceCancelResponseBean responseBean = service.cancelEInvoice(InvoiceCancelRequestBean bean);
177
</pre>
178
179
# *conn*           - Database connection.
180
# *bean*           - Object.
181
> * *cancelCode*
182
> * *cancelReason*
183
> * *invoiceIds* - List of Integer
184
185
  3. *responseBean*
186
187
> * *success* - true / false