Download the PHP package josmlt/spoonacular-laravel-wrapper without Composer

On this page you can find all versions of the php package josmlt/spoonacular-laravel-wrapper. 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 spoonacular-laravel-wrapper

Spoonacular Laravel Wrapper

What is :memo:

It's a package that uses Facades to request resources from Spoonacular API, like recipes, random recipes, nutrients and offers different sort options like for calories, intolerances etc.

Purpose

It was made to learn how Facades and Laravel packages works.

Steps to installation :information_source:

It's necessary register in Spoonacular and get an api key.

Package Locally Development :information_source:

We need to create a folder, within it we create a Laravel project and clone the repository. Structure similar to this :

After that, open composer.json file in our main Laravel project, add the next properties :

Next step is require the package to our project, execute :

We'll see the message: Installing josmlt/spoonacular-laravel-wrapper (dev-master): Junctioning from ../spoon-wrapper

Then execute the follow command, it publishes the config file :

Finally we have two options, first we could have a default value of SPOONACULAR_API_KEY, within config/spoonacular.php or as well we can add in our .env a new environment variable like SPOONACULAR_API_KEY = ""

From Packagist :information_source:

We need to pull the package from packagist to our Laravel project.

After a correct installation, we need to publish a custom config file, execute:

Finally, we move into :

And add our api key from Spoonacular, or alternative you can create a new environment variable named like SPOONACULAR_API_KEY.

How to use it :question:

:point_right: If we want to get recipes with tomato, for example, we just need to search recipes with this keyword, type:

:point_right: But what else? If you need a complex search, because for example you're intolerant with eggs or you want order the results for amount of calories ... Type :

:point_right: Or get random recipes :

Testing :heavy_check_mark:

This package provides a few tests, the objective is to get more confident using the package and check if it's possible add a new feature without broke nothing valuable.

Within the package, execute the follow : vendor/bin/phpunit tests/Unit/SpoonacularFacadeTest.php

Don't forget execute composer install after download or clone the project, also get a valid APIKEY.


All versions of spoonacular-laravel-wrapper with dependencies

PHP Build Version
Package Version
Requires php Version ^7.3|^8.0
guzzlehttp/guzzle Version ^7.0.1
illuminate/support Version ^8.50
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 josmlt/spoonacular-laravel-wrapper contains the following files

Loading the files please wait ....