101 lines
2.5 KiB
YAML
101 lines
2.5 KiB
YAML
definitions:
|
|
models.WelcomeModel:
|
|
properties:
|
|
id_daerah:
|
|
example: 1
|
|
type: integer
|
|
type: object
|
|
utils.DataValidationError:
|
|
properties:
|
|
field:
|
|
example: email
|
|
type: string
|
|
message:
|
|
example: Invalid email address
|
|
type: string
|
|
type: object
|
|
utils.RequestError:
|
|
properties:
|
|
code:
|
|
example: 422
|
|
type: integer
|
|
fields:
|
|
items:
|
|
$ref: '#/definitions/utils.DataValidationError'
|
|
type: array
|
|
message:
|
|
example: Invalid email address
|
|
type: string
|
|
type: object
|
|
info:
|
|
contact:
|
|
email: lifelinejar@mail.com
|
|
name: API Support
|
|
description: SIPD Service Transaksi Pendapatan Rest API.
|
|
license:
|
|
name: Apache 2.0
|
|
url: http://www.apache.org/licenses/LICENSE-2.0.html
|
|
termsOfService: http://swagger.io/terms/
|
|
title: SIPD Service Transaksi Pendapatan
|
|
version: "1.0"
|
|
paths:
|
|
/welcome:
|
|
get:
|
|
consumes:
|
|
- application/json
|
|
description: get welcome
|
|
parameters:
|
|
- description: Halaman yang ditampilkan
|
|
in: query
|
|
name: page
|
|
type: integer
|
|
- description: Jumlah data per halaman, maksimal 50 data
|
|
in: query
|
|
name: limit
|
|
type: integer
|
|
- description: 'Key value pencarian ([kode_ddn,nama_daerah,jns_pemda]). Contoh:
|
|
kode_ddn.11 -> (akan menampilkan data dengan kode ddn = ''11'')'
|
|
in: query
|
|
name: filter
|
|
type: string
|
|
produces:
|
|
- application/json
|
|
responses:
|
|
"200":
|
|
description: Success
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/models.WelcomeModel'
|
|
type: array
|
|
"400":
|
|
description: Bad request
|
|
schema:
|
|
$ref: '#/definitions/utils.RequestError'
|
|
"401":
|
|
description: Unauthorized
|
|
schema:
|
|
$ref: '#/definitions/utils.RequestError'
|
|
"404":
|
|
description: Not found
|
|
schema:
|
|
$ref: '#/definitions/utils.RequestError'
|
|
"422":
|
|
description: Data validation failed
|
|
schema:
|
|
items:
|
|
$ref: '#/definitions/utils.RequestError'
|
|
type: array
|
|
"500":
|
|
description: Server error
|
|
schema:
|
|
$ref: '#/definitions/utils.RequestError'
|
|
summary: get welcome
|
|
tags:
|
|
- Welcome
|
|
securityDefinitions:
|
|
ApiKeyAuth:
|
|
in: header
|
|
name: Authorization
|
|
type: apiKey
|
|
swagger: "2.0"
|