# Problem when trying to get PCSID (Passing compliance checks)

**URL:** <https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530>\
**Category:** Clearance and Reporting\
**Created:** [August 21, 2024, 12:50pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530 "2024-08-21T12:50:59Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hadi](https://avatars.discourse-cdn.com/v4/letter/h/e99b99/32.png) [@Hadi](https://zatca1.discourse.group/u/Hadi)\
**Post date:** [August 21, 2024, 12:51pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/1 "2024-08-21T12:51:00Z")

</div>

Dears ,

Many thanks for your continus support .

Now i was able to clear my standard invoices for complinance checks .

However , when i try to request PCSID , i get this message :

```auto
{"code":"Missing-ComplianceSteps","message":"The compliance certificate is not done with the following compliance steps yet [standard-credit-note-compliant,standard-debit-note-compliant,simplified-compliant,simplified-credit-note-compliant,simplified-debit-note-compliant]"}
Production CSID request failed with status code: BadRequest

```

I have 2 questions :  
1- why i’m being ask to submit simplified invoices while i submit the code 1100 on the CSR request file for invoiceType .

2- how many invoices i should submit before i pass the compliance checks .

Thanks for your great support .

---

<div class="post-metadata">

**Author:** ![Embro](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/embro/32/1689_2.png) [@Embro](https://zatca1.discourse.group/u/Embro)\
**Post date:** [August 21, 2024, 1:06pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/2 "2024-08-21T13:06:50Z")

</div>

when u request a CSID from your CSR request … you will receive a certificate … On-Boarding …with …(CN=eInvoicing)  
So using this CSID … you need to send (6 invoices …as u mentioned …1100 3 types of Standards + 3 types of Simplified)  
if it approved …you will request for another CSID …so you will get Final CSID ( CN=PEZEINVOICESCA4-CA, DC=extgazt, DC=gov, DC=local) whitch you will used in your continuos send simulation test

---

<div class="post-metadata">

**Author:** ![Hadi](https://avatars.discourse-cdn.com/v4/letter/h/e99b99/32.png) [@Hadi](https://zatca1.discourse.group/u/Hadi)\
**Post date:** [August 21, 2024, 1:17pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/3 "2024-08-21T13:17:21Z")

</div>

Dear @Embro

Thanks for your reply .

We are only doing B2B invoices . What code should I write to submit only the standard invoice (other than 1100) .

Thank you

---

<div class="post-metadata">

**Author:** ![Embro](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/embro/32/1689_2.png) [@Embro](https://zatca1.discourse.group/u/Embro)\
**Post date:** [August 21, 2024, 1:23pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/4 "2024-08-21T13:23:12Z")

</div>

based on the invoice type in your configuration file if it’s 0100 that’s mean you will only send a simplified invoice, if it’s 1000 only for standard invoices and if it is 1100 you will send both standard and simplified.

---

<div class="post-metadata">

**Author:** ![Hadi](https://avatars.discourse-cdn.com/v4/letter/h/e99b99/32.png) [@Hadi](https://zatca1.discourse.group/u/Hadi)\
**Post date:** [August 21, 2024, 1:51pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/5 "2024-08-21T13:51:59Z")

</div>

Dear @Embro

i did all the compliance checks . but now i’m getting another error when trying to get the PCSID :

```auto
Sending request for Production CSID...
Response Status Code: BadRequest
API Response Body:
{"errorCode":"400","errorCategory":"Invalid-CSR","errorMessage":"The provided Certificate Signing Request (CSR) is invalid."}
Production CSID request failed with status code: BadRequest

```

Any idea

---

<div class="post-metadata">

**Author:** ![Embro](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/embro/32/1689_2.png) [@Embro](https://zatca1.discourse.group/u/Embro)\
**Post date:** [August 21, 2024, 1:55pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/6 "2024-08-21T13:55:55Z")

</div>

> [@Hadi](#):
>
> `he provided Certificate Signing Request (CSR) is invalid`

1- Confirm that u are using your required CSR  
2- You have to finish your whole Cycle with 1 hour (calculated from the time you received rhe OTP)

---

<div class="post-metadata">

**Author:** ![Hadi](https://avatars.discourse-cdn.com/v4/letter/h/e99b99/32.png) [@Hadi](https://zatca1.discourse.group/u/Hadi)\
**Post date:** [August 21, 2024, 2:15pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/7 "2024-08-21T14:15:45Z")

</div>

Dear @Embro

Actually when generating the PCSID , I don’t submit any CSR .

we submit the binarytoken: secret key from CCSID encoded in Base64 as authorization .  
And compliance request ID as body .

am I missing something here ?

---

<div class="post-metadata">

**Author:** ![Embro](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/embro/32/1689_2.png) [@Embro](https://zatca1.discourse.group/u/Embro)\
**Post date:** [August 21, 2024, 6:12pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/8 "2024-08-21T18:12:37Z")

</div>

1- Prepare you Config file  
2- Create your Keys (Private key, Public Key)  
3- Create you CSR  
4- Take taxpayer OTP (VALID FOR 1 Hour) from ZATCA  
5- To Obtain a test Compliance Cryptographic Stamp Identifier (CCSID) and test Request ID  
Send a request (csr base64 encoded + OTP)  
6- you must receive a Response by Code 200 & response body includes your CCSID  
7- using this CCSID  
send 3 Or 6 Invoices for Approval  
'1 Standard invoice.  
'2 Standard debit note.  
'3 Standard credit note.

```
'4 Simplified Invoice.
'5 Simplified credit note.
'6 Simplified debit note.

```

8- You must receive responseCode = 200 for these invoices  
9- If Approved these sample invoices … send a request for a final production CCSID  
10- you must receive a Response by Code 200 & response body includes your CCSID

Note that these steps (for simulation and the same steps to be repeated for the core CCSID production))

I hope it helps

---

<div class="post-metadata">

**Author:** ![Hadi](https://avatars.discourse-cdn.com/v4/letter/h/e99b99/32.png) [@Hadi](https://zatca1.discourse.group/u/Hadi)\
**Post date:** [August 22, 2024, 7:25am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/9 "2024-08-22T07:25:19Z")

</div>

Dear @Embro ,

Many thanks for your reply .

Actually i found the problem .  
My CSR Information is correct . just this parameter was worng . i chosen NoProduction on a simulatoin enviroment .

Anyway , thank you for your efforts

 ![csr request](https://europe1.discourse-cdn.com/flex013/uploads/zatca1/original/1X/238162d643493d6421838601d5af307399a162bc.png)

---

<div class="post-metadata">

**Author:** ![moalnatour](https://avatars.discourse-cdn.com/v4/letter/m/9dc877/32.png) [@moalnatour](https://zatca1.discourse.group/u/moalnatour)\
**Post date:** [September 14, 2024, 12:58pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/10 "2024-09-14T12:58:57Z")

</div>

For standard and simplified sample invoices, can the customer data, invoice serial number, ICV , and PIH be represented with non-real data ?

---

<div class="post-metadata">

**Author:** ![Hadi](https://avatars.discourse-cdn.com/v4/letter/h/e99b99/32.png) [@Hadi](https://zatca1.discourse.group/u/Hadi)\
**Post date:** [September 14, 2024, 2:35pm UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/11 "2024-09-14T14:35:47Z")

</div>

You can use anything for simulation and non Production environment .

But for production it should be real

---

<div class="post-metadata">

**Author:** ![sayedrahman](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/sayedrahman/32/475_2.png) [@sayedrahman](https://zatca1.discourse.group/u/sayedrahman)\
**Post date:** [September 30, 2024, 7:47am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/12 "2024-09-30T07:47:52Z")

</div>

“The compliance certificate is not done with the following compliance steps yet [simplified-debit-note-compliant]”

I am getting this error but all are my invoices returning 200.

do i have to test all invoices in particular time??

---

<div class="post-metadata">

**Author:** ![anusv](https://avatars.discourse-cdn.com/v4/letter/a/dc4da7/32.png) [@anusv](https://zatca1.discourse.group/u/anusv)\
**Post date:** [September 30, 2024, 7:51am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/13 "2024-09-30T07:51:48Z")

</div>

@sayedrahman you haven’t completed all the compliant steps

---

<div class="post-metadata">

**Author:** ![sayedrahman](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/sayedrahman/32/475_2.png) [@sayedrahman](https://zatca1.discourse.group/u/sayedrahman)\
**Post date:** [September 30, 2024, 7:55am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/14 "2024-09-30T07:55:32Z")

</div>

yes i know, Can you please tell me more about what is simplified debit note??

---

<div class="post-metadata">

**Author:** ![Ather](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/ather/32/848_2.png) [@Ather](https://zatca1.discourse.group/u/Ather)\
**Post date:** [September 30, 2024, 8:17am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/15 "2024-09-30T08:17:04Z")

</div>

@sayedrahman

**Simplified Debit Note**

> \<cbc:InvoiceTypeCode name=“0200000”\>383\</cbc:InvoiceTypeCode\>

**Simplified Credit Note**

> \<cbc:InvoiceTypeCode name=“0200000”\>381\</cbc:InvoiceTypeCode\>

---

<div class="post-metadata">

**Author:** ![sayedrahman](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/sayedrahman/32/475_2.png) [@sayedrahman](https://zatca1.discourse.group/u/sayedrahman)\
**Post date:** [September 30, 2024, 8:27am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/16 "2024-09-30T08:27:53Z")

</div>

but what is debit simplified invoice?? when it need to create??

---

<div class="post-metadata">

**Author:** ![Ather](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/ather/32/848_2.png) [@Ather](https://zatca1.discourse.group/u/Ather)\
**Post date:** [September 30, 2024, 8:33am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/17 "2024-09-30T08:33:45Z")

</div>

1. When a customer was charged incorrectly on an invoice.
2. If there were unexpected costs incurred (like shipping or handling fees) that were not included in the original invoice.
3. If the price of goods or services has changed after the initial invoice was issued.
4. If there’s a change in terms that requires an additional charge based on the agreement.
5. If there were unexpected costs incurred (like shipping or handling fees) that were not included in the original invoice.

---

<div class="post-metadata">

**Author:** ![sayedrahman](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/sayedrahman/32/475_2.png) [@sayedrahman](https://zatca1.discourse.group/u/sayedrahman)\
**Post date:** [September 30, 2024, 8:36am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/18 "2024-09-30T08:36:25Z")

</div>

Thanks you so much,

will you give me one nice format where you done it, I am getting no error or warning when i doing compliance in simulation but when i try to get pcsid, it showing simplified debit not has been done compliance

---

<div class="post-metadata">

**Author:** ![Ather](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/ather/32/848_2.png) [@Ather](https://zatca1.discourse.group/u/Ather)\
**Post date:** [September 30, 2024, 8:44am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/19 "2024-09-30T08:44:35Z")

</div>

Check the END Points correctly in that case, particularly for Simplified Debit Note

---

<div class="post-metadata">

**Author:** ![sayedrahman](https://dub1.discourse-cdn.com/flex013/user_avatar/zatca1.discourse.group/sayedrahman/32/475_2.png) [@sayedrahman](https://zatca1.discourse.group/u/sayedrahman)\
**Post date:** [September 30, 2024, 8:53am UTC](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530/20 "2024-09-30T08:53:37Z")

</div>

Do i have to test it within any particular time?? like after generate CSID i have to test it with one hour, or i can generate any time after test ??

[Next page](https://zatca1.discourse.group/t/problem-when-trying-to-get-pcsid-passing-compliance-checks/2530.md?page=2)
