承接 posts/posts-client 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

posts/posts-client

Composer 安装命令:

composer require posts/posts-client

包简介

Сервис пользовательских постов

README 文档

README

Сервис пользовательских постов

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

  • API version: 1.0.0
  • Build package: org.openapitools.codegen.languages.PhpClientCodegen For more information, please visit https://ensi.tech/contacts

Requirements

PHP 5.5 and later

Installation & Usage

Composer

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

{
  "repositories": [
    {
      "type": "vcs",
      "url": "https://gitlab.com/greensight/ensi/backend-service-skeleton-client-php.git"
    }
  ],
  "require": {
    "posts/posts-client": "*@dev"
  }
}

Then run composer install

Manual Installation

Download the files and include autoload.php:

    require_once('/path/to/PostsClient/vendor/autoload.php');

Tests

To run the unit tests:

composer install
./vendor/bin/phpunit

Getting Started

Please follow the installation procedure and then run the following:

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



$apiInstance = new Posts\PostsClient\Api\PostsApi(
    // 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()
);
$create_post_request = new \Posts\PostsClient\Dto\CreatePostRequest(); // \Posts\PostsClient\Dto\CreatePostRequest | 

try {
    $result = $apiInstance->createPost($create_post_request);
    print_r($result);
} catch (Exception $e) {
    echo 'Exception when calling PostsApi->createPost: ', $e->getMessage(), PHP_EOL;
}

?>

Documentation for API Endpoints

All URIs are relative to http://localhost/api/v1

ClassMethodHTTP requestDescription
PostsApicreatePostPOST /postsСоздание поста
PostsApideletePostDELETE /posts/{id}Удаление поста
PostsApigetPostGET /posts/{id}Получение поста по id
PostsApipatchPostPATCH /posts/{id}Обновление поста
PostsApisearchPostPOST /posts:search-oneПоиск одного поста
PostsApisearchPostsPOST /posts:searchПоиск постов
UsersVotesApicreateUserVotePOST /users-votesСоздание голоса пользователя
UsersVotesApideleteUserVoteDELETE /users-votes/{id}Удаление голоса пользователя
UsersVotesApigetUserVoteGET /users-votes/{id}Получение голоса пользователя по id
UsersVotesApipatchUserVotePATCH /users-votes/{id}Обновление голоса пользователя
UsersVotesApisearchUsersVotesPOST /users-votes:searchПоиск голоса пользователя

Documentation For Models

Documentation For Authorization

All endpoints do not require authorization.

Author

ignatev@greensight.ru

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2024-07-11