Download the PHP package naif/saudiaddress without Composer
On this page you can find all versions of the php package naif/saudiaddress. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download naif/saudiaddress
More information about naif/saudiaddress
Files in naif/saudiaddress
Package saudiaddress
Short Description Laravel wrapper for the Saudi National Address APIs
License MIT
Informations about the package saudiaddress
Saudi Address - Laravel Package
Laravel wrapper for the Saudi National Address APIs.
Requirements
- PHP >= 7.2
- Laravel 5.5 - 12.x
Installation
Laravel 5.5+ uses auto-discovery, so the service provider and facade are registered automatically.
For Laravel < 5.5, add to config/app.php:
Configuration
API Key
Get your API key from https://api.address.gov.sa/ and add it to your .env:
The default API URL is already configured. Override it only if needed:
Optional Settings
Publish Config
To customize the configuration file:
Usage
Get Regions
Get Cities
Get Districts
Reverse Geocode
Get address details from latitude/longitude coordinates:
Verify Address
Verify an address by building number, postal code, and additional number:
Free-Text Address Search
Search for addresses using free-text query:
Fixed-Parameter Address Search
Search for addresses using specific parameters:
Bulk Address Search
Search for multiple addresses at once (up to 10):
Short Address Lookup
Look up a national address by short address code (4 letters + 4 digits):
Verify Short Address
Check whether a short address code is valid:
POI Free-Text Search
Search for points of interest using free text:
POI Fixed-Parameter Search
Search for points of interest with specific parameters:
Nearest POI
Find nearest points of interest by coordinates:
Service Categories
Get service categories for POI search:
Service Sub-Categories
Get sub-categories for a given service category:
Send OTP (Address By Phone)
Send OTP to a mobile number for address lookup:
Address By Phone
Get addresses associated with a phone number after OTP verification:
Feature Extents
Get geographic extents for a feature layer:
Error Handling
All methods throw typed exceptions that extend SaudiAddressException:
Testing
Support
- Author: Naif Alshaye ([email protected])
- LinkedIn: https://www.linkedin.com/in/naif
License
The MIT License (MIT). Please see License File for more information.
All versions of saudiaddress with dependencies
guzzlehttp/guzzle Version ^6.3|^7.0
illuminate/support Version ^5.5|^6.0|^7.0|^8.0|^9.0|^10.0|^11.0|^12.0