Download the PHP package targito/targito-api-bundle without Composer

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

Targito API Symfony Bundle for Symfony 4 & 5

Build Status

To see description of the api methods, see the library description

Installation

composer require targito/targito-api-bundle

If you use Symfony Flex the bundle should be enabled automatically. If you're not using it, add Targito\Bundle\Api\TargitoApiBundle to your config/bundles.php file:

If you want to change any of the default settings, create a file targito_api.yaml in your config/packages directory with key targito_api:

Note: You can let Symfony generate the default config for you like this: ./bin/console config:dump targito_api > config/packages/targito_api.yaml

Usage

Simply use the provided services (with autowiring support):

Examples

Get the whole api service:

Get specific api module:

Configuring credentials

By default, the bundle takes the credentials from environment variables TARGITO_ACCOUNT_ID and TARGITO_API_PASSWORD.

If you want to provide the credentials other way, read on, otherwise you can skip this section.

There are two built-in options for specifying credentials: via environment variables or explicitly. You can also specify your own credentials service.

Explicit

When using explicit mode, the credentials must be also specified inside the config.

Environment variables

When using environment variables, you can optionally specify the environment variable names.

Custom service

You can specify your own service which implements the Targito\Api\Credentials\CredentialsInterface interface.

Configuring http request service

By default, this bundle (and underlying library) choose automatically between curl and stream based implementations. You can provide your own (or use the curl/stream library regardless of curl support on the PHP level). The service must implement Targito\Api\Http\HttpRequestInterface.

or

or

Full configuration reference (autogenerated)


All versions of targito-api-bundle with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2|^8.0
symfony/framework-bundle Version ^4.4|^5.0
symfony/yaml Version ^4.4|^5.0
targito/targito-api Version ^1.3.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 targito/targito-api-bundle contains the following files

Loading the files please wait ....