urlr/urlr-php 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

urlr/urlr-php

最新稳定版本:3.0.2

Composer 安装命令:

composer require urlr/urlr-php

包简介

PHP client for URLR

README 文档

README

Packagist Version Packagist Downloads Packagist License

This SDK is automatically generated with the OpenAPI Generator project.

  • API version: 2.0.0
  • Package version: 3.0.2
  • Build package: urlr/urlr-php

For more information, please visit https://urlr.me/en.

Installation & Usage

Requirements

PHP 8.1 and later.

Composer

You can install the bindings via Composer. Run the following command:

composer require urlr/urlr-php

Manual Installation

Download the files and include autoload.php:

<?php
require_once('/path/to/URLR/vendor/autoload.php');

Getting Started

Please follow the installation procedure and then run the following:

<?php

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

$apiKey = getenv('URLR_API_KEY'); // to be defined on your side

// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
$client =  new GuzzleHttp\Client();

$configuration = URLR\Configuration::getDefaultConfiguration()
    ->setApiKey('X-API-KEY', $apiKey);

// Create a link

$linksApi = new URLR\Api\LinksApi($client, $configuration);

$linkCreateRequest = new \URLR\Model\LinkCreateRequest([
    'url' => '',
    'workspaceId' => '',
]);

try {
    $link = $linksApi->linkCreate($linkCreateRequest);
} catch (Exception $e) {
    echo 'Exception when calling LinksApi->linkCreate: ', $e->getMessage(), PHP_EOL;
}

Complete examples can be found in the docs directory of the client repository.

API Endpoints

All URIs are relative to https://urlr.me/api/v2

Class Method HTTP request Description
DomainsApi domainCreate POST /domains Create a domain
DomainsApi domainGet GET /domains/{domain_id} Get a domain
DomainsApi domainList GET /domains List domains
FoldersApi folderCreate POST /folders Create a folder
FoldersApi folderGet GET /folders/{folder_id} Get a folder
FoldersApi folderList GET /folders List folders
LinksApi linkCreate POST /links Create a link
LinksApi linkDelete DELETE /links/{link_id} Delete a link
LinksApi linkEdit PATCH /links/{link_id} Edit a link
LinksApi linkGet GET /links/{link_id} Get a link
LinksApi linkList GET /links List links
QRCodesApi qrcodeCreate POST /qrcodes Create a QR Code
StatisticsApi statisticGet GET /statistics Get statistics
WorkspacesApi workspaceGet GET /workspaces/{workspace_id} Get a workspace
WorkspacesApi workspaceList GET /workspaces List workspaces of user

Models

Authorization

ApiKeyAuth

  • Type: API key
  • API key parameter name: X-API-KEY
  • Location: HTTP header

Tests

To run the tests, use:

composer install
vendor/bin/phpunit

Get help / support

Please contact contact@urlr.me and we can take more direct action toward finding a solution.

统计信息

  • 总下载量: 288
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 4
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-07-26

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固