42videobricks/php-client

42videobricks is a Video Platform As A Service (VPaaS)

v1.7.6 2025-03-06 13:10 UTC

This package is auto-updated.

Last update: 2025-03-06 13:11:45 UTC


README

42videobricks is a Video Platform As A Service (VPaaS)

Installation & Usage

Requirements

PHP 7.4 and later. Should also work with PHP 8.0.

Composer

To install the bindings via Composer, add the following to composer.json:

{
  "repositories": [
    {
      "type": "vcs",
      "url": "https://github.com/GIT_USER_ID/GIT_REPO_ID.git"
    }
  ],
  "require": {
    "GIT_USER_ID/GIT_REPO_ID": "*@dev"
  }
}

Then run composer install

Manual Installation

Download the files and include autoload.php:

<?php
require_once('/path/to/Package\Subpackage/vendor/autoload.php');

Getting Started

Please follow the installation procedure and then run the following:

<?php
require_once(__DIR__ . '/vendor/autoload.php');



// Configure API key authorization: api_key
$config = Api42Vb\Client\Configuration::getDefaultConfiguration()->setApiKey('x-api-key', 'YOUR_API_KEY');
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// $config = Api42Vb\Client\Configuration::getDefaultConfiguration()->setApiKeyPrefix('x-api-key', 'Bearer');


$apiInstance = new Api42Vb\Client\Api\DataApi(
    // If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
    // This is optional, `GuzzleHttp\Client` will be used as default.
    new GuzzleHttp\Client(),
    $config
);
$limit = 56; // int | Number of elements to return (default=10)
$offset = 56; // int | offset for pagination
$start_date = {{starDate}}; // string | Start date for the period
$end_date = {{endDate}}; // string | End date for the period

try {
    $result = $apiInstance->getDataVideoAnalytics($limit, $offset, $start_date, $end_date);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling DataApi->getDataVideoAnalytics: ', $e->getMessage(), PHP_EOL;
}

API Endpoints

All URIs are relative to https://api-sbx.42videobricks.com

Class Method HTTP request Description
DataApi getDataVideoAnalytics GET /data/videos/analytics List Video Analytics KPIs
DataApi getDataVideoUsage GET /data/videos/usage List Video Usage KPIs
LivesApi addLive POST /lives Create a live event
LivesApi addSlateByLiveIdAndName POST /lives/{liveId}/slate/{slateName} Upload an image file and set it as a slate for a live event
LivesApi addThumbnailByLiveId POST /lives/{liveId}/thumbnail Upload an image file and set it as the Thumbnail for a video
LivesApi deleteLiveById DELETE /lives/{liveId} Delete a live event
LivesApi getLiveById GET /lives/{liveId} Get details of a live event
LivesApi getLives GET /lives Retrieve a list of live events
LivesApi getLivesCaptureSources GET /lives/captureSources Retrieve a list of capture sources
LivesApi getScenesByLiveId GET /lives/{liveId}/scenes List of the scenes in the live event
LivesApi startStopLiveById PUT /lives/{liveId}/{action} Active a live
LivesApi updateLiveById PUT /lives/{liveId} Update details of a live event
LivesApi updateStateOfScene PUT /lives/{liveId}/scenes/{sceneName}/{state} Update the state of a scene based on its id
PlayerApi deletePlayers DELETE /players/{playerId} delete players
PlayerApi getPlayers GET /players List players
PlayersApi addPlayer POST /players Add a new player
PlayersApi updatePlayer PUT /players/{playerId} Update player
PlayersApi uploadLogoPlayer POST /players/{playerId}/upload Upload a logo to the player theme
PlaylistsApi addPlaylist POST /playlists Add a new playlist
PlaylistsApi deletePlaylistById DELETE /playlists/{playlistId} Delete a playlist
PlaylistsApi getPlaylistById GET /playlists/{playlistId} Retun a single playlist
PlaylistsApi getPlaylists GET /playlists List playlists
PlaylistsApi updatePlaylistById PUT /playlists/{playlistId} Update an existing playlist
TagsApi getTags GET /tags List Video Tags
VideosApi addAttachmentByVideoId POST /videos/{videoId}/attachments/{attachmentType}/{locale} Upload an attachement
VideosApi addThumbnailByVideoId POST /videos/{videoId}/thumbnail Upload a thumbnail
VideosApi addVideo POST /videos Add a new video
VideosApi deleteAttachmentByVideoId DELETE /videos/{videoId}/attachments/{attachmentType}/{locale} Delete an attachment
VideosApi deleteExportToVideo DELETE /videos/{videoId}/exports/{format} Delete an export of the video
VideosApi deleteLinkToVideo DELETE /videos/{videoId}/links/{linkType} Delete a link
VideosApi deleteThumbnailByVideoId DELETE /videos/{videoId}/thumbnail Delete a thumbnail
VideosApi deleteVideoById DELETE /videos/{videoId} Delete a video
VideosApi finalizeMultipartUploadVideoById POST /videos/{videoId}/multipart-upload/finalize Multipart upload finalization
VideosApi finalizeUploadVideoById PUT /videos/{videoId}/upload/finalize Single file upload finalization
VideosApi getAttachmentByVideoId GET /videos/{videoId}/attachments/{attachmentType}/{locale} Get the attachment
VideosApi getAttachmentFileByVideoId GET /videos/{videoId}/attachments/{attachmentType}/{locale}/file Get attachement file
VideosApi getAttachmentsByVideoId GET /videos/{videoId}/attachments List of attachments
VideosApi getDetailToVideoById GET /videos/{videoId}/detail Get the detail of metadatas
VideosApi getExportToVideoById GET /videos/{videoId}/exports Get the list exports of the video
VideosApi getExportUrlToVideoById GET /videos/{videoId}/exports/{format} Get an url of the export of the video
VideosApi getVideoById GET /videos/{videoId} Retun a single video
VideosApi getVideoStatusById GET /videos/{videoId}/status Retun the detailed status of the video
VideosApi getVideos GET /videos List videos
VideosApi initMultipartUploadVideoById POST /videos/{videoId}/multipart-upload/init Multipart upload intialization
VideosApi initUploadVideoById GET /videos/{videoId}/upload/init Single file upload intialization
VideosApi moveEnvironmentVideoById PUT /videos/{videoId}/moveTo/{environment} Update environment of video
VideosApi postExportToVideo POST /videos/{videoId}/exports/{format} Add export to the video
VideosApi postLinkToVideo POST /videos/{videoId}/links Add link to the video
VideosApi putLinkToVideo PUT /videos/{videoId}/links/{linkType} Update link to the video
VideosApi updateVideoById PUT /videos/{videoId} Update an existing video
WebhooksApi addWebhook POST /webhooks Add a new webhook
WebhooksApi deleteWebhookById DELETE /webhooks/{webhookId} Delete a webhook
WebhooksApi getWebhookById GET /webhooks/{webhookId} Retun a single webhook
WebhooksApi getWebhooks GET /webhooks List webhooks
WebhooksApi updateWebhookById PUT /webhooks/{webhookId} Update an existing webhook

Models

Authorization

Authentication schemes defined for the API:

api_key

  • Type: API key
  • API key parameter name: x-api-key
  • Location: HTTP header

Tests

To run the tests, use:

composer install
vendor/bin/phpunit

Author

About this package

This PHP package is automatically generated by the OpenAPI Generator project:

  • API version: 1.5
    • Package version: 1.7.7
  • Build package: org.openapitools.codegen.languages.PhpClientCodegen