idesigning / yaga-order
Requires
- php: >=5.4
- ext-curl: *
- ext-json: *
- ext-mbstring: *
- jms/serializer-bundle: *
- symfony/framework-bundle: ^2.3|^3.0
- symfony/validator: *
Requires (Dev)
- friendsofphp/php-cs-fixer: ~1.12
- hoa/regex: ~1.0
- phpunit/phpunit: ~4.8
- satooshi/php-coveralls: ~1.0
- squizlabs/php_codesniffer: ~2.6
- symfony/browser-kit: *
This package is not auto-updated.
Last update: 2024-04-23 18:26:49 UTC
README
Common schema for Yaga order requests. Swagger
This Symfony bundle is automatically generated by the Swagger Codegen project:
- API version: 18.40.0
- Build package: io.swagger.codegen.languages.SymfonyServerCodegen
Requirements
PHP 5.4.0 and later
Installation & Usage
To install the dependencies via Composer, add the following repository to composer.json
of your Symfony project:
{
"repositories": [{
"type": "path",
"url": "//Path to your generated swagger bundle"
}],
}
Then run:
composer require swagger/server-bundle:dev-master
to add the generated swagger bundle as a dependency.
Tests
To run the unit tests for the generated bundle, first navigate to the directory containing the code, then run the following commands:
composer install
./vendor/bin/phpunit
Getting Started
Step 1: Please follow the installation procedure first.
Step 2: Enable the bundle in the kernel:
<?php
// app/AppKernel.php
public function registerBundles()
{
$bundles = array(
// ...
new YagaOrder\Server\SwaggerServerBundle(),
// ...
);
}
Step 3: Register the routes:
# app/config/routing.yml
swagger_server:
resource: "@SwaggerServerBundle/Resources/config/routing.yml"
Step 4: Implement the API calls:
<?php
// src/Acme/MyBundle/Api/YagaOrderApiInterface.php
namespace Acme\MyBundle\Api;
use YagaOrder\Server\Api\YagaOrderApiInterface;
class YagaOrderApi implements YagaOrderApiInterface // An interface is autogenerated
{
// Other operation methods ...
}
Step 5: Tag your API implementation:
# src/Acme/MyBundle/Resources/services.yml
services:
# ...
acme.my_bundle.api.yagaOrder:
class: Acme\MyBundle\Api\YagaOrderApi
tags:
- { name: "swagger_server.api", api: "yagaOrder" }
# ...
Now you can start using the bundle!
Documentation for API Endpoints
All URIs are relative to https://localhost
Class | Method | HTTP request | Description |
---|---|---|---|
YagaOrderApiInterface | bookTickets | POST /book | |
YagaOrderApiInterface | cancelPayedReservation | POST /cancel-order | |
YagaOrderApiInterface | clearReservation | POST /clear-reservation | |
YagaOrderApiInterface | getOrder | POST /order-info | |
YagaOrderApiInterface | getOrderStatus | POST /order-status | |
YagaOrderApiInterface | getSessionSeats | GET /available-seats | |
YagaOrderApiInterface | getTicketPdf | GET /pdf/{ticketId} | |
YagaOrderApiInterface | refundNotify | POST /refund-notify | |
YagaOrderApiInterface | reserveTickets | POST /reserve | |
YagaOrderApiInterface | saleApprove | POST /approve |
Documentation For Models
- Addition
- AdditionLimits
- AdmissionState
- AttachmentType
- BarcodeType
- BookTicketsResult
- BytesValue
- Cost
- Customer
- Delivery
- DeliveryType
- EventType
- GetSessionSeatsResult
- LevelState
- Money
- Order
- OrderItem
- OrderStatus
- OrderStatusResult
- PaymentType
- RefundNotify
- RequestOrder
- ReserveTicketsResult
- Seat
- SeatCategory
- SeatState
- SessionTime
- SessionType
- SoldTicket
- SupplementType
Documentation For Authorization
All endpoints do not require authorization.