CDK Global adopt API
The adopt API from CDK Global — 2 operation(s) for adopt.
The adopt API from CDK Global — 2 operation(s) for adopt.
swagger: '2.0'
info:
version: 3.0.0
title: appointments adopt API
description: "## Fortellis - Service - Appointments\nA service appointment is a booking of a vehicle into the service department for work that needs to be carried out on the vehicle. This could be a service, repair, body repair, government test etc.\n\n## What does this API do?\nThe API will allow you to query, create and manage service appointments. \n\n## Intended Audience\nIt is expected that systems that require create, read, update, and delete access to appointments will use this API. Systems implementing service-scheduling will use this API to store appointment records.\n"
contact:
name: Developer Evangelists
url: https://example.com
email: support@fortellis.io
host: fortellis.io
basePath: /sales/notification/v3
schemes:
- https
security:
- permission-model:
- anonymous
tags:
- name: adopt
paths:
/pets:
get:
summary: Query pets available for adoption
description: Query pets available for adoption
operationId: queryPets
tags:
- adopt
parameters:
- $ref: '#/parameters/header.Request-Id'
- $ref: '#/parameters/header.Subscription-Id'
- $ref: '#/parameters/header.Authorization'
- $ref: '#/parameters/query.name'
- $ref: '#/parameters/query.breed'
- $ref: '#/parameters/query.page'
- $ref: '#/parameters/query.pageSize'
consumes:
- application/json
produces:
- application/json
responses:
'200':
$ref: '#/responses/PetCollection'
'400':
$ref: '#/responses/BadRequest'
'401':
$ref: '#/responses/Unauthorized'
'403':
$ref: '#/responses/Forbidden'
'503':
$ref: '#/responses/ServiceUnavailable'
/pets/{petId}:
get:
summary: Get the description of a pet available for adoption
description: Get the description of a pet available for adoption
operationId: readPets
tags:
- adopt
parameters:
- $ref: '#/parameters/header.Request-Id'
- $ref: '#/parameters/header.Subscription-Id'
- $ref: '#/parameters/header.Authorization'
- $ref: '#/parameters/path.petId'
consumes:
- application/json
produces:
- application/json
responses:
'200':
$ref: '#/responses/Pet'
'400':
$ref: '#/responses/BadRequest'
'401':
$ref: '#/responses/Unauthorized'
'403':
$ref: '#/responses/Forbidden'
'404':
$ref: '#/responses/NotFound'
'503':
$ref: '#/responses/ServiceUnavailable'
definitions:
CollectionNavigationObject:
description: The standard set of links to navigate a resource collection
type: object
properties:
firstPage:
type: string
description: The URL to the first page of query results
nextPage:
type: string
description: The URL to the next page of query results
prevPage:
type: string
description: The URL to the previous page of query results
required:
- firstPage
- nextPage
- prevPage
example:
firstPage: https://api.fortellis.io/pet-adoption/v1/pets?page=1&pageSize=20
nextPage: https://api.fortellis.io/pet-adoption/v1/pets?page=3&pageSize=20
prevPage: https://api.fortellis.io/pet-adoption/v1/pets?page=2&pageSize=20
PetCollection:
description: A search result collection of Pet records.
properties:
items:
type: array
items:
$ref: '#/definitions/Pet'
description: Pet search results.
totalItems:
type: number
description: The total number of items contained in the collection
totalPages:
type: number
description: The total number of pages given the requested page size
links:
$ref: '#/definitions/CollectionNavigationObject'
description: The hypermedia links describing the possible resource actions
required:
- items
- totalItems
- totalPages
- links
example:
items:
- petId: ABC123
name: Fido
type: dog
- petId: DEF456
name: Fluffy
type: cat
- petId: GHI789
name: Rex
type: dog
totalItems: 10
totalPages: 4
links:
firstPage: https://api.fortellis.io/pet-adoption/v1/pets?page=1&pageSize=3
nextPage: https://api.fortellis.io/pet-adoption/v1/pets?page=2&pageSize=3
prevPage: https://api.fortellis.io/pet-adoption/v1/pets?page=1&pageSize=3
Pet:
description: A pet record
properties:
petId:
type: string
description: The record identifier of the pet
name:
type: string
description: The name of the pet
type:
type: string
enum:
- dog
- cat
description: The type of pet
required:
- petId
- name
- type
example:
petId: ABC123
name: Fido
type: dog
ErrorResponse:
description: Common error response object.
properties:
code:
type: integer
format: int32
message:
type: string
required:
- code
- message
example:
code: 400
message: Bad Request
parameters:
header.Authorization:
name: Authorization
in: header
type: string
description: "Contains credentials that allows the caller to authenticate itself with the \nAPI. See RFC 7235 and RFC 7617 for more details.\n"
path.petId:
name: petId
in: path
type: string
required: true
description: The unique identifier of a pet adoption record.
query.breed:
name: breed
in: query
type: string
description: Allows pet searches to be filtered by breed
query.page:
name: page
in: query
type: number
minimum: 1
description: "This is a pagination control for the request page of query result items\nto return in the response. It must be greater than or equal to one. If \ngreater than the total number of available pages, the returned page will \nbe the last available page.\n"
header.Subscription-Id:
name: Subscription-Id
in: header
required: true
type: string
format: guid
description: The Fortellis Marketplace subscription identifier between a user entity and the solution. For sample responses use the Subscription-Id 'test'.
header.Request-Id:
name: Request-Id
in: header
required: true
type: string
format: uuid
description: "A correlation ID that should be returned back to the caller to \nindicate the return of the given request\n"
query.pageSize:
name: pageSize
in: query
type: number
minimum: 1
description: 'This is a pagination control for the requested number of items returned
per page. It must be greater than or equal to one. This may be overridden
and clamped to a maximum value by the resource owner.
'
query.name:
name: name
in: query
type: string
description: Allows pet searches to be filtered by name
responses:
Unauthorized:
description: 401 - Unauthorized
headers:
Request-Id:
type: string
schema:
$ref: '#/definitions/ErrorResponse'
Forbidden:
description: 403 - Forbidden
headers:
Request-Id:
type: string
schema:
$ref: '#/definitions/ErrorResponse'
BadRequest:
description: 400 - Bad Request
headers:
Request-Id:
type: string
schema:
$ref: '#/definitions/ErrorResponse'
Pet:
description: OK
schema:
$ref: '#/definitions/Pet'
ServiceUnavailable:
description: 503 - Service Unavailable
headers:
Request-Id:
type: string
schema:
$ref: '#/definitions/ErrorResponse'
PetCollection:
description: OK
schema:
$ref: '#/definitions/PetCollection'
NotFound:
description: 404 - Not Found
headers:
Request-Id:
type: string
schema:
$ref: '#/definitions/ErrorResponse'
securityDefinitions:
permission-model:
type: oauth2
flow: implicit
authorizationUrl: https://identity.fortellis.io/oauth2/
scopes:
anonymous: Create, Query, Update, and Delete appointments