openapi: 3.1.0
info:
  title: One Geo Survey API
  description: Api สำหรับการใช้งานระบบข้อมูลทางภูมิศาสตร์
  version: 1.0.0
  contact:
    email: admin@ogs.co.th
    url: https://ogs.co.th/
  "x-logo":
    {
      "url": "/assets/ogs/mark.png",
      "backgroundColor": "#fafafa",
      "altText": "OGS logo",
    }
servers:

  - url: https://map-osrm.onegeo.co.th
    description: ตัวประมวลผลแผนที่ [Production]
#  - url: https://map-osrm-uat.onegeo.co.th
#    description: ตัวประมวลผลแผนที่ [Uat]

  - url : https://maptile.onegeo.co.th
    description: แผนที่ [Production]
#  - url: https://maptile-uat.onegeo.co.th
#    description: แผนที่ [Uat]

  - url: https://places.onegeo.co.th
    description: ข้อมูลแผนที่ [Production]
#  - url: https://places-uat.onegeo.co.th
#    description: ข้อมูลแผนที่ [Uat]

  - url: https://geoserver.onegeo.co.th
    description: ชั้นข้อมูล [Production]
#  - url: https://geoserver-uat.onegeo.co.th
#    description: ชั้นข้อมูล [Uat]

  - url: https://map-util.ogs.co.th
    description: เครื่องมือเสริม [Production]
#  - url: https://map-util-uat.ogs.co.th
#    description: เครื่องมือเสริม [Uat]

paths:
  /v1/search:
    $ref: "./paths/v1/search/get.yml"
  /v1/reverse:
    $ref: "./paths/v1/reverse/get.yml"
  /get-code:
    $ref: "./paths/v1/get-code/get.yml"
  /route/v1/{type}/{coordinates}:
    $ref: "./paths/v1/driving/get.yml"
  /v1/nominatim/restaurant:
    $ref: "./paths/v1/nominatim/restaurant/post.yml"
  /geoserver/OGS/wms:
    $ref: "./paths/v1/wms-layers/get.yml"
  /location/is-in-thailand:
    $ref: "./paths/v1/location/is-in-thailand/get.yml"
  /tile/{x}/{y}/{z}.png:
    $ref: "./paths/tile/get.yml"
  /get-centroid:
    $ref: "./paths/centroid/get.yml"
components:
  securitySchemes:
    ApiKeyHeader:
      type: apiKey
      in: header
      name: ApiKey
    ApiKeyQuery:
      type: apiKey
      in: query
      name: Apikey


tags:
  - name: การค้นหาข้อมูล
    description: Api สำหรับการทำงานเกี่ยวกับการค้นหาสถานที่
  - name: จัดการข้อมูลแผน
    description: Api สำหรับการจัดการข้อมูลแผนที่
  - name: คำนวณเส้นทาง
    description: Api สำหรับการงานคำนวณข้อมูลแผนที่
  - name: ขอบเขตพื้นที่ประเทศไทย
    description: Api สำหรับแสดงขอบเขตพื้นที่ประเทศไทย
  - name: ตรวจสอบข้อมูล
    description: Api สำหรับแสดงขอบเขตพื้นที่ประเทศไทย
  - name: ข้อมูลแผนที่
    description: Service สำหรับแสดงข้อมูลภูมิศาสตร์
  - name: Introduction
    description: Introductory endpoints

x-tagGroups:
  - name: ข้อมูลสถานที่
    tags:
      - การค้นหาข้อมูล
      - จัดการข้อมูลแผน
      - ตรวจสอบข้อมูล
  - name: คำนวณแผนที่
    tags:
      - คำนวณเส้นทาง
  - name: ชั้นข้อมูลแผนที่
    tags:
      - ชั้นข้อมูลแผนที่
