This package is not installable via Composer 1.x, please make sure you upgrade to Composer 2+. Read more about our Composer 1.x deprecation policy.

PHP wrapper for Ow-API

1.0.3 2020-08-19 10:54 UTC

This package is auto-updated.

Last update: 2021-06-28 21:34:05 UTC


MIT License Current Version


This repository contains an unofficial PHP wrapper for the Ow-API.

API resources and response examples are in the Official Documentation.

Table of contents


This library requires PHP v7.1 or higher.


Use the below code to install the wrapper:

composer require fnev-eu/ow-api-php

How to use



require 'vendor/autoload.php';

use \OwAPI\Client;

$client = new Client(); 

// Get profile data for player Ori#21337 (it's me!), 
$response = $client->profile(Client::PLATFORMS['PC'], Client::REGIONS['EU'], 'Ori#21337');

// Read the response
if ($response->isSuccess()) {
    echo $response->getBody()['name'];

// Other available methods:
// - ALL profile data, heavy endpoint
$completeStats = $client->completeStats(Client::PLATFORMS['PC'], Client::REGIONS['EU'], 'Ori#21337');

// - Get profile data for specific heroes:
$heroesStats = $client->heroes(
    ['brigitte', 'mercy', 'ana']

The profile, completeStats and heroes method will return a Response with the following methods:

  • isSuccess: returns a boolean indicating if the API call was successful
  • getStatus: HTTP status code
  • getBody: PHP associative array from the JSON response
  • getRequest and getRawResponse to help you for debug


Feel free to ask anything and contribute:

  • Fork the project
  • Create a new branch
  • Implement your idea or fix
  • Commit, push and open a pull request!