Download the PHP package hyraiq/abnlookup without Composer

On this page you can find all versions of the php package hyraiq/abnlookup. 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 abnlookup

hyraiq/abnlookup

A PHP SDK to validate Australian Business Numbers (ABNs) and verify them with the Australian Business Register Web Services API. The difference between validation and verification can be outlined as follows:

In order to use the API (only necessary for verification), you'll need to register an account to receive a GUID which is used as an API key. Once you register you can play with the API using the official demo (note that this SDK uses the JSON services instead of XML).

Type safety

The SDK utilises the Symfony Serializer and the Symfony Validator to deserialize and validate data returned from the ABR API in order to provide valid AbnResponse and NamesResponse models. This means that if you receive a response from the SDK, it is guaranteed to be valid.

Invalid responses from the ABR fall into three categories, which are handled with exceptions:

Usage

Installation

Configuration with Symfony

In services.yaml, you need to pass you ABR GUID to the AbnClient and register the AbnClient with the AbnClientInterface:

You can then inject the AbnClientInterface directly into your controllers/services.

Configuration outside of Symfony

If you're not using Symfony, you'll need to instantiate the ABN client yourself, which can be registered in your service container or just used directly. We have provided some helpers in the Dependencies class in order to create the Symfony Serializer and Validator with minimal options.

Looking up an ABN

Once you have configured your AbnClient you can lookup an individual ABN. Note, this will validate the ABN before calling the API in order to prevent unnecessary API requests.

Searching by name

You can also search the ABR by name, to receive a list of registered businesses that match the search term:

Testing

In automated tests, you can replace the AbnClient with the StubAbnClient in order to mock responses from the ABR. There is also the AbnFaker which you can use during tests to get both valid and invalid ABNs.

Contributing

All contributions are welcome! You'll need docker installed in order to run tests and CI processes locally. These will also be run against your pull request with any failures added as GitHub annotations in the Files view.

In order for you PR to be accepted, it will need to be covered by tests and be accepted by:


All versions of abnlookup with dependencies

PHP Build Version
Package Version
Requires php Version >=8.0
ext-json Version *
phpdocumentor/reflection-docblock Version ^5.3
phpstan/phpdoc-parser Version ^1.2
symfony/cache Version ^5.0 | ^6.0
symfony/http-client Version ^5.0 | ^6.0
symfony/property-access Version ^5.0 | ^6.0
symfony/property-info Version ^5.0 | ^6.0
symfony/serializer Version ^5.0 | ^6.0
symfony/validator Version ^5.0 | ^6.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 hyraiq/abnlookup contains the following files

Loading the files please wait ....