# 602 - Save Document

602 - Save Document

<table data-header-hidden><thead><tr><th width="171.7786429365962">Event</th><th width="226">Extension action set</th><th>Description</th></tr></thead><tbody><tr><td><a href="#before">Before </a></td><td>EXT_0602_1_Before</td><td>Will be executed before MSS saves the receipt;</td></tr><tr><td><a href="#replace">Replace</a></td><td>EXT_0602_2_Replace</td><td>Will be executed before MSS saves the receipt with the possibility to say MSS to cancel the saving process;</td></tr><tr><td>After</td><td>EXT_0602_3_After</td><td>Will be executed after the receipt is saved;</td></tr></tbody></table>

### Before

*Input Parameters*

* inReceiptExercise – Exercise of the receipt;
* inReceiptType – Type of the receipt;
* inReceiptSeries – Series of the receipt;
* inReceiptNumber – Number of the receipt;
* inCustomerCode – Code of the selected customer;

### Replace

*Input Parameters*

* inReceiptExercise – Exercise of the receipt;
* inReceiptType – Type of the receipt;
* inReceiptSeries – Series of the receipt;
* inReceiptNumber – Number of the receipt;
* inCustomerCode – Code of the selected customer;

*Output Parameters*

* outCanSave – Return code: 1 – Save the document / 0 – Cancel


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.sysdevmobile.com/mss-extensibility/mss-5.1/functions-mss-to-kalipso/receipts/602-receipts-save-document.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
