Project

General

Profile

Specification » History » Version 24

Soh Keong, 06/12/2024 04:48 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 23 Soh Keong
"Jar":/redmine/attachments/787
15 1 Soh Keong
"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 13 Soh Keong
InvoiceSubmissionResponseBean responseBean = service.submitEInvoice(Connection conn, List<InvoiceSubmissionRequestBean> beanList);
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 13 Soh Keong
# *beanList*       - InvoiceSubmissionRequestBean List.
49 1 Soh Keong
> * *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 14 Soh Keong
> * *supplierBean*
59
> ** *addressBean* 
60
> *** *country*  - CommonConstant.COUNTRY_* (https://sdk.myinvois.hasil.gov.my/codes/countries/)
61
> *** *state*    - CommonConstant.STATE_* (https://sdk.myinvois.hasil.gov.my/codes/state-codes/)
62
> *** *city*     - Max length : 50
63
> *** *postal*   - Max length : 50
64
> *** *address1* - Max length : 150
65
> *** *address2* - Max length : 150
66
> *** *address3* - Max length : 150
67
> ** *contactNumber* - Max length : 20
68
> ** *name*          - Max length : 300
69
> ** *registrationBean*
70 17 Soh Keong
> *** *tin*      
71
> *** *idType*     
72
> *** *idValue* 
73 14 Soh Keong
> *** *sst*      (Optional)
74 24 Soh Keong
> *** *msic*    - https://sdk.myinvois.hasil.gov.my/codes/msic-codes/ 
75 14 Soh Keong
76 1 Soh Keong
> * *buyerBean* 
77 14 Soh Keong
> ** *addressBean* 
78 11 Soh Keong
> *** *country*  - CommonConstant.COUNTRY_* (https://sdk.myinvois.hasil.gov.my/codes/countries/)
79 10 Soh Keong
> *** *state*    - CommonConstant.STATE_* (https://sdk.myinvois.hasil.gov.my/codes/state-codes/)
80
> *** *city*     - Max length : 50
81
> *** *address1* - Max length : 150
82
> *** *address2* - Max length : 150
83
> *** *address3* - Max length : 150
84 1 Soh Keong
> ** *contactNumber* - Max length : 20
85 10 Soh Keong
> ** *name*          - Max length : 300
86 14 Soh Keong
> ** *registrationBean*
87 18 Soh Keong
> *** *tin*      
88 22 Soh Keong
> *** *idType*     - CommonConstant.ID_TYPE_* 
89 18 Soh Keong
> *** *idValue* 
90 2 Soh Keong
> *** *sst*      (Optional)
91 6 Soh Keong
92 11 Soh Keong
> * *productList*
93 19 Soh Keong
> ** *productName*            - Max length : 300
94
> ** *productCode*            - Max length :  18
95
> ** *measurement* (Optional) - CommonConstant.MEASUREMENT_* (https://sdk.myinvois.hasil.gov.my/codes/unit-types/)
96
> ** *quantity*    (Optional) 
97 6 Soh Keong
> ** *totalExcludingTax*
98 11 Soh Keong
> ** *unitPrice*
99
> ** *subtotal*
100
> ** *classificationList* 
101 19 Soh Keong
> *** *code*                 - CommonConstant.CLASSIFICATION_CODE_* (https://sdk.myinvois.hasil.gov.my/codes/classification-codes/)
102
> *** *group*                - CommonConstant.CLASSIFICATION_GROUP_* 
103 6 Soh Keong
> ** *taxTotalBean*
104 12 Soh Keong
> *** *totalTaxAmount*
105 8 Soh Keong
> *** *taxSubTotalList*
106 1 Soh Keong
> **** *taxType*          - CommonConstant.TAX_TYPE_* (https://sdk.myinvois.hasil.gov.my/codes/tax-types/)
107
> **** *percent*          (Optional)
108 8 Soh Keong
> **** *perUnitAmount*    (Optional)
109 14 Soh Keong
> **** *measurement*      (Optional) - CommonConstant.MEASUREMENT_* (https://sdk.myinvois.hasil.gov.my/codes/unit-types/)
110 16 Soh Keong
> **** *quantity*         (Optional)
111 3 Soh Keong
> **** *netAmount*        (Optional)
112
> **** *tax*
113 6 Soh Keong
114
> * *taxTotalBean*
115
> ** *totalTaxAmount*
116 1 Soh Keong
> ** *taxSubTotalList*
117
> *** *taxType*
118 6 Soh Keong
> *** *percent*
119
> *** *perUnitAmount*
120 14 Soh Keong
> *** *measurement*
121
> *** *quantity*
122 1 Soh Keong
> *** *netAmount*
123
> *** *tax*
124
125
  3. *responseBean*
126
127
> * *submissionUid*
128
> * *acceptedDocumentList*
129
> ** *orderId*
130
> ** *uuid*
131
> * *rejectedDocumentList*
132
> ** *orderId*
133
> ** *errorList*
134 4 Soh Keong
> *** *code*
135 8 Soh Keong
> *** *message*
136
137
138 10 Soh Keong
h3. queryEInvoice
139 8 Soh Keong
140
<pre>
141 10 Soh Keong
InvoiceInquiryResponseBean responseBean = service.queryEInvoice(Connection conn, InvoiceInquiryRequestBean bean);
142 8 Soh Keong
</pre>
143
144
# *conn*           - Database connection.
145 9 Soh Keong
# *bean*           - Object.
146
> * *documentNum*
147
> * *submissionUid*
148
> * *invoiceUuid*
149
> * *invoiceTypeCode*
150
> * *buyerTin*
151
> * *buyerName*
152 15 Soh Keong
> * *supplierTin*
153
> * *supplierName*
154 9 Soh Keong
> * *totalAmountFrom*
155
> * *totalAmountTo*
156
> * *invoiceStatus*
157
> * *confirmStatusCode*
158
> * *issuedDateFrom*
159
> * *issuedDateTo*
160
> * *pageIndex* (Mandatory)
161
> * *pageSize* (Mandatory)
162
163
  3. *responseBean*
164
165
> * *page*
166
> ** *pageCount*
167
> ** *pageNo*
168
> ** *pageSize*
169
> ** *totalSize*
170
171
> * *recordList*
172
> ** *buyerTin*
173
> ** *confirmStatusCode*
174
> ** *currency*
175 1 Soh Keong
> ** *description*
176
> ** *documentNum*
177
> ** *excludingTaxAmount*
178
> ** *includingTaxAmount*
179
> ** *invoiceId*
180
> ** *invoiceStatus*
181
> ** *invoiceTypeCode*
182
> ** *invoiceUuid*
183
> ** *issuedDate*
184
> ** *nowTime*
185
> ** *operationDate*
186
> ** *operator*
187
> ** *pageIndex*
188
> ** *pageNo*
189
> ** *pageSize*
190 15 Soh Keong
> ** *supplierTin*
191
> ** *supplierName*
192 1 Soh Keong
> ** *submissionUid*
193 9 Soh Keong
> ** *transactionId*
194 10 Soh Keong
195
h3. cancelEInvoice
196
197
<pre>
198
InvoiceCancelResponseBean responseBean = service.cancelEInvoice(InvoiceCancelRequestBean bean);
199
</pre>
200
201
# *conn*           - Database connection.
202
# *bean*           - Object.
203 12 Soh Keong
> * *cancelCode*   - CommonConstant.CANCEL_CODE_* 
204
> * *cancelReason* - (Mandatory for CommonConstant.CANCEL_CODE_OTHERS) 
205 10 Soh Keong
> * *invoiceIds* - List of Integer
206
207
  3. *responseBean*
208
209
> * *success* - true / false