Easy-to-use SDK for implementing Neshan APIs in your Laravel projects.

Overview

Logo

Neshan Laravel SDK

Easy-to-use SDK for implementing Neshan APIs in your Laravel projects.


Install

The easiest way to install is by using Composer:

composer require ehsan_coder/neshan-laravel

Composer is a dependency manager for PHP which allows you to declare the libraries your project depends on, and it will manage (install/update) them for you. If you are not familiar with Composer, you can read its documentations and download it via getcomposer.org.

configuration .env file

add account information into .env file

NESHAN_API_KEY=your neshan api key

usage

To use the package, you need an API key. To get that you should have a Neshan account. Register and get your API key.
Use NeshanFacade on top of your controller or wherever you want:

use EhsanCoder\NeshanLaravel\NeshanFacade;

all APIs of Neshan exist in this Facade! for example to use distanceMatrix API we can use:

$response = EhsanCoder\NeshanLaravel\NeshanFacade::distanceMatrix($origins, $destinations, $type, $timeout = 10);

for Example

$response = EhsanCoder\NeshanLaravel\NeshanFacade::distanceMatrix('36.279589071020425,50.00901454609652','38.279589071020425,51.00901454609652', EhsanCoder\NeshanLaravel\NeshanAPI::DISTANCE_MATRIX_CAR_TYPE);

Parameters

Parameter Required Description Type Example
$origins Yes all origins! every origin must separated by pipe character string 36.279589071020425,50.00901454609652
$destinations Yes same of origins parameter string 38.279589071020425,51.00901454609652
$type No default value is car string car
$timeout No default value of timeout is 5 sec int 10
You might also like...
Nebula is a minimalistic and easy to use administration tool for Laravel applications, made with Laravel, Alpine.js, and Tailwind CSS.

Nebula Nebula is a minimalistic and easy to use administration tool for Laravel applications, made with Laravel, Alpine.js, and Tailwind CSS. Nebula m

A Laravel 8 Project Implement with GraphQL With Sanctum APIs Authentications Which utilized in Any Frontend or Any Mobile Application Programs.

A Laravel 8 Project Implement with GraphQL With Sanctum APIs Authentications Which utilized in Any Frontend or Any Mobile Application Programs.

A package to access messari apis for laravel

Messari API - Laravel Laravel wrapper for messari.io API Full API documentation could be found on messari.io Installation PHP 7.2+ and Composer are re

Get started using SELCOM APIs with Laravel framework

About Laravel Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experie

Laravel-api - crud and login/signup apis

About Laravel Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experie

A simple API wrapper to Gigapay's APIs for Laravel Framework
A simple API wrapper to Gigapay's APIs for Laravel Framework

Laravel-Gigapay A simple API wrapper for Gigapay's APIs. It gives you helper methods that will make your work with gigapay's API easy, fast and effici

Backend application using Laravel 9.x REST APIs for games topup from digiflazz.com and payment gateway using xendit.co

TOPUP - Laravel 9.x REST API Documentation is still on progress. For now, you can fork this postman collection Installation Clone this project git clo

Execute Laravel Artisan commands via REST APIs and HTTP requests safely.

Artisan Api There might be some times you wanted to execute an Artisan command, but you did not have access to shell or SSH. Here we brought REST API

Quickly generate pivot tables for your projects
Quickly generate pivot tables for your projects

Laravel Pivot Table Generator Quickly generate pivot tables for your projects! Table of Contents Installation Usage More generator packages Contributi

Releases(v1.1.1)
Owner
null
Builds nice, normalized and easy to consume REST JSON responses for Laravel powered APIs.

REST API Response Builder for Laravel Master branch: Development branch: Table of contents Introduction Why should I use it? Usage examples Features E

Marcin Orlowski 611 Dec 5, 2022
Llum illuminates your Laravel projects speeding up your Github/Laravel development workflow

Llum illuminates your Laravel projects speeding up your Github/Laravel development workflow

Sergi Tur Badenas 108 Oct 26, 2022
Laravel User Activity Log - a package for Laravel 8.x that provides easy to use features to log the activities of the users of your Laravel app

Laravel User Activity Log - a package for Laravel 8.x that provides easy to use features to log the activities of the users of your Laravel app

null 8 Nov 29, 2022
These projects are free for public use. Be a lesson for those who violate the rights of others!! ✌️

Faraz Kish Projects These projects are free for public use. Be a lesson for those who violate the rights of others!! ✌️ Brands Farazkish Uinvest MFina

Milad Shahi 30 May 20, 2022
A collection of helper functions that I use across my projects.

A collection of helper functions that I use across my projects. This package includes some of the helper functions that I tend to use in all of my pro

Ryan Chandler 33 Oct 18, 2022
Easily Integrate PingPing APIs in your Laravel Project

PingPing This composer package allows us to easily integrate PingPing APIs in your Laravel project. What is PingPing ? PingPing is the simplest uptime

Bhushan Gaikwad 15 Mar 22, 2022
Laravel Backend API for the tutorial (Granular permissions with Laravel APIs & React frontend)

Laravel Granular Permissions Backend Getting Started Clone the repository. Install the dependencies composer install Update .env database credentials

Munaf Aqeel Mahdi 4 May 10, 2022
👀 Manage your views in Laravel projects through artisan

Artisan View This package adds a handful of view-related commands to Artisan in your Laravel project. Generate blade files that extend other views, sc

Sven Luijten 835 Nov 18, 2022
Easily set up a sync endpoint to support Watermelon DB in your Laravel projects.

Laravel Watermelon This package provides a Watermelon DB backend sync implementation for Laravel. Watermelon DB is a robust local database synchroniza

Nathan Heffley 17 Aug 24, 2022
Laravel-FCM is an easy to use package working with both Laravel and Lumen for sending push notification with Firebase Cloud Messaging (FCM).

Laravel-FCM Introduction Laravel-FCM is an easy to use package working with both Laravel and Lumen for sending push notification with Firebase Cloud M

Rahul Thapa 2 Oct 16, 2022