> For the complete documentation index, see [llms.txt](https://developer.nilvera.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developer.nilvera.com/api/magaza-api/fatura-islemleri/faturayi-magazaya-gonderir..md).

# Faturayı mağazaya gönderir.

Faturanın mağazaya yüklenme durumu sipariş bilgisinde `InvoiceUploadStatus` olarak dönülür.

`InvoiceUploadStatus` değerleri;\
`None = 0`&#x20;Sipariş kaydedildiğindeki ilk değeridir.

`Waiting = 1`&#x20;Fatura mağazaya gönderme işlemi tetiklendiğinde oluşur.

`Success = 2`&#x20;Mağazaya başarılı yüklemede oluşur.

`Error = 3` Faturanın mağazaya yüklenmesi sırasında hata oluştuğunda atanır. Mağaza tarafında çözülebilecek bir durumsa mağazaya gönderme yeniden tetiklenebilir.

## POST /Invoices/SendStore

> Faturayı mağazaya gönderir

```json
{"openapi":"3.0.1","info":{"title":"Market Place API","version":"v1"},"servers":[{"url":"/marketplace"}],"security":[{"Bearer":[]}],"components":{"securitySchemes":{"Bearer":{"type":"http","description":"API Key Giriniz","scheme":"Bearer","bearerFormat":"JWT"}},"schemas":{"SendInvoiceToStoreCommand":{"type":"object","properties":{"OrderUUID":{"type":"string","format":"uuid"},"StoreUUID":{"type":"string","format":"uuid"}},"additionalProperties":false},"SendModelResponse":{"type":"object","properties":{"IsSuccess":{"type":"boolean"},"OrderNumber":{"type":"string","nullable":true},"InvoiceDetail":{"$ref":"#/components/schemas/InvoiceDetail"},"ErrorDetail":{"type":"array","items":{"$ref":"#/components/schemas/ErrorNilvera"},"nullable":true}},"additionalProperties":false},"InvoiceDetail":{"type":"object","properties":{"InvoiceNumber":{"type":"string","nullable":true},"UUID":{"type":"string","nullable":true},"TaxNumber":{"type":"string","nullable":true},"DocumentType":{"type":"string","nullable":true}},"additionalProperties":false},"ErrorNilvera":{"type":"object","properties":{"Code":{"$ref":"#/components/schemas/ErrorCodes"},"Description":{"type":"string","nullable":true},"Detail":{"type":"string","nullable":true}},"additionalProperties":false},"ErrorCodes":{"enum":["TaxNumberNotRecordedForCompany","UUIDAlreadySaved","IncompatibleOperationType","InvoiceAutomaticallyAccepted","InvoiceAlreadySaved","InvoiceSerieAlreadyUsed","BasicInvoiceDoesNotAcceptAnswer","InvoiceAlreadyAnswered","DespatchAutomaticallyAccepted","DespatchAlreadySaved","DespatchSerieAlreadyUsed","DespatchAlreadyAnswered","EArchiveInvoiceAlreadySaved","VoucherAlreadySaved","ProducerAlreadySaved","RecordAlreadyExists","CompanyStoragePackageAlreadyExists","VoucherSerieAlreadyUsed","ProducerSerieAlreadyUsed","BillSerieAlreadyUsed","BillAlreadySaved","InsuranceSerieAlreadyUsed","EArchiveInvoiceSerieAlreadyUsed","NotEnoughCredit","CompanyInformationAddError","StorageSpaceNotEnough","BringBranchesError","RecordFailure","FileUploadError","TemplateUpdateError","DocumentOpenZipError","DocumentSerializeError","DocumentProcessError","BringDocumentAttachmentError","CreateEnvelopeError","DocumentReadError","RecordDeleteError","PdfCreateError","SchemaSchematronError","BringStatisticsError","FileTypeInCorrect","InvalidValueForSendType","ProcessCountCanNotBeOver100","IncompatibleFileContent","BringExchangeRatesError","UpdateError","PreviewCreateError","FileScenarioMustBeEArchiveDocument","ReceiverEInvoicePersonCanNotSendEArchive","InvoiceAlreadyCanceled","InvoiceCanNotCanceledWhenReportInCorrect","DocumentCanNotCanceledWhenInQueueOrStatusNotFound","CancelRecordCreateError","InvoiceRecordRevertCancelAlreadyReported","CancelRecordRevertError","SerieNotActive","SerieAliasCanNotBeEmpty","VoucherAlreadyCanceled","VoucherCanNotCanceledWhenReportInCorrect","VoucherDocumentCanNotCanceledWhenInQueueOrStatusNotFound","VoucherCancelRecordCreateError","VoucherRecordRevertCancelAlreadyReported","VoucherCancelRecordRevertError","VoucherSerieNotActive","VoucherSerieAliasCanNotBeEmpty","ProducerAlreadyCanceled","ProducerDocumentCanNotCanceledWhenInQueueOrStatusNotFound","ProducerCancelRecordCreateError","ProducerRecordRevertCancelAlreadyReported","ProducerCancelRecordRevertError","ProducerSerieNotActive","ProducerSerieAliasCanNotBeEmpty","ReportCanNotBeQueried","ReportCreationError","SenderNotEInvoicePerson","ReceiverAliasNotInUse","ReceiverBecameEInvoiceInDate","ReceiverNotEInvoicePerson","ReceiverAliasCanNotBeEmpty","ReceiverAliasInUse","BringAliasError","InvoiceMustBePaperOrEArchive","InvoiceScenarioMustBePublic","InvoiceScenarioMustBeEArchive","InvoiceScenarioCanNotBePublic","InvoiceAnswerUpdateError","InvoiceScenarioEArchiveMustBeEInvoice","InvoiceSerieNotActive","InvoiceSerieAliasCanNotBeEmpty","SenderNotEDespatchPerson","ReceiverBecameEDespatchInDate","DespatchDocumentCanNotSendToVirtualReceiver","DespatchDocumentMustSentToVirtualReceiver","DespatchBringAliasError","DespatchNotWaitForAnswer","DespatchScenarioMustBe","DespatchSerieNotActive","DespatchSerieAliasCanNotBeEmpty","CreditPackageDateExpired","StoragePackageDateExpired","StoragePackageNotEnough","CreditPackageNotEnough","ProducerCanNotCanceledWhenReportInCorrect","BillAlreadyCanceled","BillDocumentCanNotCanceledWhenInQueueOrStatusNotFound","BillCancelRecordCreateError","BillRecordRevertCancelAlreadyReported","BillCancelRecordRevertError","BillSerieNotActive","BillSerieAliasCanNotBeEmpty","PdfReadError","LedgerCreatedBefore","LedgerCreateError","LedgerStructureError","LedgerCreationIsInProgress","CertificatesDoNotMatch","SignError","AmountValueMustBeaNumber","EnteredDateFieldIncorrectFormat","LedgerSendingProcessContinues","AccountingPeriodMust12Months","NormalAccountingPeriodFailure","UpdatingLedgerStatusFailure","SerieAndDocumentYearMismatch","BillCanNotCanceledWhenReportInCorrect","ConvertUblError","ValidateUblError","UblCompanyInfoError","InvoiceTransferErpError","IncorrectStockMatchingQueryFormat","InvoiceLineItemError","SendTypeError","FileSizeCannotBeZero","InsuranceAleadyCanceled","InsuranceCanNotCanceledWhenReportInCorrect","InsuranceDocumentCanNotCanceledWhenInQueueOrStatusNotFound","InsuranceCancelRecordCreateError","InsuranceRecordRevertCancelAlreadyReported","IncorrectLegalAmountTotal","PaymentAmountDoesntMatch","ReceiverAliasNotFound","SenderAliasNotFound","AliasNotRegistered","DocumentNotFound","RecordNotFound","DocumentContentEmpty","ReportNotFound","ToBeReportedInvoiceNotFound","ToBeReportedVoucherNotFound","SerieNotBelongToCompany","TemplateNotFound","TemplateNotActivate","CompanyTemplateNotFound","EmailModuleNotActive","WhatsappModuleNotActive","SmsModuleNotActive","CompanyNotBelongToDealer","PackageCodeNotFound","SubDealerCodeNotFound","ToBeReportedBillNotFound","StorageModuleNotFound","EledgerPropartiesNotFound","AccountantNotFound","CertificatesNotFound","CompanyErpSettingNotFound","LedgerQueryNotFound","NotBeQuestioned","SignatureValueNotFound","LedgerReportNotFound","DesignModuleNotActive","APINotFound","ConnectorPropertiesNotFound","CompanyErpNotFound","QueryNotFound","DataNotFound","CompanyErpUserNotFound","CompanyStockNotFound","CompanySerieNotFound","StoreTypeNotFound"],"type":"string"}}},"paths":{"/Invoices/SendStore":{"post":{"tags":["Invoices"],"summary":"Faturayı mağazaya gönderir","requestBody":{"content":{"application/json-patch+json":{"schema":{"$ref":"#/components/schemas/SendInvoiceToStoreCommand"}},"application/json":{"schema":{"$ref":"#/components/schemas/SendInvoiceToStoreCommand"}},"text/json":{"schema":{"$ref":"#/components/schemas/SendInvoiceToStoreCommand"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/SendInvoiceToStoreCommand"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SendModelResponse"}}}}}}}}}}
```
