Download the PHP package sevaske/php-zatca-xml without Composer

On this page you can find all versions of the php package sevaske/php-zatca-xml. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package php-zatca-xml

php Vers ion Packagist Stars Packagist Downloads Packagist Version License

Please feel free to contribute if you are missing features or tags
View Examples Β· Report a bug

FORK!

Note: The original author of the repository Saleh7/php-zatca-xml has been inactive and unresponsive for several months.

This repository is a community-maintained fork with fixes and updates to keep the library functional and improved.

All changes and bug fixes are collected here to support users and continue development.

Namespaces:
The original namespace Saleh7\Zatca has not been changed to maintain compatibility.

Future Merge:
If the original author returns and resumes activity, we are open to merging all changes and improvements back into the original repository.

API Integration:
API-related functionality has been refactored and moved to a separate library for better modularity and maintainability:
πŸ”— sevaske/zatca-api

Original project: https://github.com/Saleh7/php-zatca-xml

πŸ“– Introduction

This is an unofficial PHP library for generating ZATCA Fatoora e-invoices (simplified invoice, simplified credit note, simplified debit note, standard invoice, standard credit note, standard debit note), certificates, and for interacting with the API.

✨ Features

πŸ“Œ Requirements

βœ… PHP Version

πŸ›  Installation

πŸš€ Usage

This library simplifies the process of generating ZATCA-compliant e-invoices, handling certificates, signing invoices, and submitting them to ZATCA’s API.

You can find working examples for generating and signing invoices and notes here:

πŸ”— examples


πŸ“œ 1. Generating a Compliance Certificate

First, generate a certificate signing request (CSR) and private key:

πŸ” 2. Requesting a Compliance Certificate from ZATCA

Once the CSR is generated, you need to request a compliance certificate from ZATCA's API.

🧾 3. Generating and signing an Invoice XML

Now that we have the compliance certificate, we can generate a ZATCA-compliant e-invoice in XML format.

Example of the simplified invoice:

Other examples you can find in the ./examples folder.

πŸ“€ 5. Submitting the Signed Invoice to ZATCA

Once the invoice is digitally signed, it can be submitted to ZATCA’s API for compliance validation and clearance.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

This project is licensed under the MIT License.


All versions of php-zatca-xml with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
ext-fileinfo Version *
ext-mbstring Version *
ext-dom Version *
ext-libxml Version *
ext-openssl Version *
ext-hash Version *
sabre/xml Version ^4.0
psr/http-message Version ^2.0
psr/http-client Version ^1.0
phpseclib/phpseclib Version ^3.0
sevaske/zatca-api Version ^1.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package sevaske/php-zatca-xml contains the following files

Loading the files please wait ....