Skip to content

modufolio/php-ninox-api

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MIT licensed

PHP Ninox REST-API Client/Wrapper

This libary allows you to quickly and easily perform REST actions on the Ninox backend using PHP.

Installation

Prerequisites

  • PHP version ^7.4
  • Ninox Account including API function

Ninox API-Docs

Ninox-API

Install Package

Add Ninox-API to your composer.json file. If you are not using Composer, we highly recommend it. It's an excellent way to manage dependencies in your PHP application.

composer require 4leads/php-ninox-api

Usage

Set team_id and/or database_id static or dynamic

use Ninox\Ninox;

$client = new Ninox("API_KEY");
//either set team_id and/or databse globally
Ninox::setFixTeam("teamId");
Ninox::setFixDatabase("databseId");
$client->listTables();
//or set it on every request (overwrites global settings for this request if set)
$client->listTables("databseId2","teamId2");
//or just override database id but use global teamId
$client->listTables("databseId3");

On private cloud/on-premise systems

use Ninox\Ninox;
$client = new Ninox("API_KEY",["host" => "yourprivate.host.com"]);
//or
$client = new Ninox("API_KEY",["host" => "yourprivate.host.com/TEAMID/api/v1"]);
//or
$client = new Ninox("API_KEY",["host" => "yourprivate.host.com"], "TEAMID");

On private-cloud/on-premise endpoints the call listTeams is not available. It is advised to set the teamid on construct, which will be used as global setting.

File Up-/Downloads

The library uses bare curl functions for file up-/downloads. This may lead to problems on bigger files. Consider script runtime and curl timeout on bigger files as well.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 100.0%