PHPackages                             leaseweb/api-caller-bundle-ivisedo - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [HTTP &amp; Networking](/categories/http)
4. /
5. leaseweb/api-caller-bundle-ivisedo

ActiveSymfony-bundle[HTTP &amp; Networking](/categories/http)

leaseweb/api-caller-bundle-ivisedo
==================================

cURL API call functionality with full Web Debug Toolbar integration

v1.1.4(11y ago)020MITPHPPHP &gt;=5.3.2

Since Apr 8Pushed 11y ago1 watchersCompare

[ Source](https://github.com/ivisedo-byhours/LswApiCallerBundle-ivisedo)[ Packagist](https://packagist.org/packages/leaseweb/api-caller-bundle-ivisedo)[ Docs](http://www.leaseweblabs.com)[ RSS](/packages/leaseweb-api-caller-bundle-ivisedo/feed)WikiDiscussions master Synced 4w ago

READMEChangelog (1)Dependencies (8)Versions (12)Used By (0)

LswApiCallerBundle
==================

[](#lswapicallerbundle)

[![screenshot](https://camo.githubusercontent.com/c6f0d7b7e8c2cf2c03426b29d5a71f4b6d95075a20fe584b9a7f724c8587cc1a/687474703a2f2f7777772e6c656173657765626c6162732e636f6d2f77702d636f6e74656e742f75706c6f6164732f323031332f30312f6170695f63616c6c65722e706e67)](https://camo.githubusercontent.com/c6f0d7b7e8c2cf2c03426b29d5a71f4b6d95075a20fe584b9a7f724c8587cc1a/687474703a2f2f7777772e6c656173657765626c6162732e636f6d2f77702d636f6e74656e742f75706c6f6164732f323031332f30312f6170695f63616c6c65722e706e67)

The LswApiCallerBundle adds a CURL API caller to your Symfony2 application. It is easy to use from the code and is aimed to have full debugging capabilities.

[Read the LeaseWebLabs blog about LswApiCallerBundle](http://www.leaseweblabs.com/2013/01/symfony2-bundle-for-curl-api-calling/)

Requirements
------------

[](#requirements)

- PHP 5.3 with curl support
- Symfony 2.1 (works under Symfony 2.0 as well)

Installation
------------

[](#installation)

Installation is broken down in the following steps:

1. Download LswApiCallerBundle using composer
2. Enable the Bundle
3. Make sure the cURL module in PHP is enabled

### Step 1: Download LswApiCallerBundle using composer

[](#step-1-download-lswapicallerbundle-using-composer)

Add LswApiCallerBundle in your composer.json:

```
{
    "require": {
        "leaseweb/api-caller-bundle": "*",
        ...
    }
}
```

Now tell composer to download the bundle by running the command:

```
$ php composer.phar update leaseweb/api-caller-bundle
```

Composer will install the bundle to your project's `vendor/leaseweb` directory.

### Step 2: Enable the bundle

[](#step-2-enable-the-bundle)

Enable the bundle in the kernel:

```

```

It should display that the option "cURL support" is set to "enabled".

This package should work on a Windows installation as well provided the CURL support is enabled in PHP.

Usage
-----

[](#usage)

You can use the caller by getting the service "api\_caller" and using the "call" function with one of the available call types:

- HttpGetJson
- HttpPostJson
- HttpPutJson
- HttpDeleteJson
- HttpGetHtml

Example of usage with the "HttpGetJson" call type:

```
use Symfony\Bundle\FrameworkBundle\Controller\Controller
use Lsw\ApiCallerBundle\Call\HttpGetJson;

class SomeController extends Controller
{
    public function someAction()
    {
        ...
        $output = $this->get('api_caller')->call(new HttpGetJson($url, $parameters));

        $entities = $output[0];
        $httpCode = $output[1];
        ...
    }
}
```

Configuration
-------------

[](#configuration)

By default it uses these cURL options:

```
parameters:
    api_caller.options:
        timeout: 10  # maximum transport + execution duration of the call in sec.
        ssl_verifypeer: false  # to stop cURL from verifying the peer's certificate.
        useragent: "LeaseWeb API Caller"  # contents of the "User-Agent: " header.
        followlocation: true  # to follow any "Location: " header that the server sends.
        sslversion: 3  # set to 3 to avoid any bugs that relate to automatic version selection.
        fresh_connect: false  # set to true to force full reconnect every call.
```

License
-------

[](#license)

This bundle is under the MIT license.

The "wall-socket" icon in the web debug toolbar is part of the Picas icon set (official website: ). The icon is licensed and may only be used to identifying the LswApiCallerBundle in the Symfony2 web debug toolbar. All ownership and copyright of this icon remain the property of Rok Benedik.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~54 days

Recently: every ~87 days

Total

11

Last Release

4238d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c5ef0e56cfb26a078941e5fd10cabe05a856bf02c6d04fbceff8ab245759f927?d=identicon)[ivisedo-byhours](/maintainers/ivisedo-byhours)

---

Top Contributors

[![Minras](https://avatars.githubusercontent.com/u/1045750?v=4)](https://github.com/Minras "Minras (2 commits)")[![spoelwijk](https://avatars.githubusercontent.com/u/81775?v=4)](https://github.com/spoelwijk "spoelwijk (1 commits)")[![TNAJanssen](https://avatars.githubusercontent.com/u/2812277?v=4)](https://github.com/TNAJanssen "TNAJanssen (1 commits)")[![zakharovvi](https://avatars.githubusercontent.com/u/1424281?v=4)](https://github.com/zakharovvi "zakharovvi (1 commits)")

---

Tags

apicurlSymfony2

### Embed Badge

![Health badge](/badges/leaseweb-api-caller-bundle-ivisedo/health.svg)

```
[![Health](https://phpackages.com/badges/leaseweb-api-caller-bundle-ivisedo/health.svg)](https://phpackages.com/packages/leaseweb-api-caller-bundle-ivisedo)
```

###  Alternatives

[nategood/httpful

A Readable, Chainable, REST friendly, PHP HTTP Client

1.8k17.2M266](/packages/nategood-httpful)[leaseweb/api-caller-bundle

cURL API call functionality with full Web Debug Toolbar integration

64417.4k1](/packages/leaseweb-api-caller-bundle)[serpapi/google-search-results-php

Get Google, Bing, Baidu, Ebay, Yahoo, Yandex, Home depot, Naver, Apple, Duckduckgo, Youtube search results via SerpApi.com

69114.3k](/packages/serpapi-google-search-results-php)[e-moe/guzzle6-bundle

Integrates Guzzle 6 into your Symfony application

11259.2k](/packages/e-moe-guzzle6-bundle)[ismaeltoe/osms

PHP library wrapper of the Orange SMS API.

4540.0k](/packages/ismaeltoe-osms)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
