openapi: 3.0.3 info: title: N2YO Satellite Tracking API description: >- The N2YO REST API provides data for software and web developers to build satellite tracking and prediction applications. The REST API v1 is free but transaction limited. All endpoints require an apiKey query parameter. version: 1.0.0 contact: name: N2YO Support url: https://www.n2yo.com/api/ license: name: N2YO API Terms url: https://www.n2yo.com/api/ servers: - url: https://api.n2yo.com/rest/v1/satellite description: Production server security: - apiKey: [] tags: - name: TLE description: Two-Line Element data for satellites. - name: Positions description: Future satellite positions over an observer location. - name: Visual Passes description: Optically visible satellite pass predictions. - name: Radio Passes description: Radio-communication satellite pass predictions. - name: Above description: Satellites currently above an observer location. paths: /tle/{id}: get: tags: - TLE summary: Get TLE for a satellite description: Retrieves the Two Line Element set for a satellite by NORAD ID. operationId: getTLE parameters: - $ref: '#/components/parameters/SatelliteId' - $ref: '#/components/parameters/ApiKey' responses: '200': description: TLE data for the satellite. content: application/json: schema: $ref: '#/components/schemas/TLEResponse' /positions/{id}/{observer_lat}/{observer_lng}/{observer_alt}/{seconds}: get: tags: - Positions summary: Get satellite positions description: >- Retrieves future positions of a satellite for the next N seconds (max 300) over an observer location. operationId: getPositions parameters: - $ref: '#/components/parameters/SatelliteId' - $ref: '#/components/parameters/ObserverLat' - $ref: '#/components/parameters/ObserverLng' - $ref: '#/components/parameters/ObserverAlt' - name: seconds in: path required: true description: Number of future seconds to return (max 300). schema: type: integer maximum: 300 - $ref: '#/components/parameters/ApiKey' responses: '200': description: Position predictions. content: application/json: schema: $ref: '#/components/schemas/PositionsResponse' /visualpasses/{id}/{observer_lat}/{observer_lng}/{observer_alt}/{days}/{min_visibility}: get: tags: - Visual Passes summary: Get visual passes description: Predicts optically visible satellite passes over an observer. operationId: getVisualPasses parameters: - $ref: '#/components/parameters/SatelliteId' - $ref: '#/components/parameters/ObserverLat' - $ref: '#/components/parameters/ObserverLng' - $ref: '#/components/parameters/ObserverAlt' - name: days in: path required: true description: Days of prediction (max 10). schema: type: integer maximum: 10 - name: min_visibility in: path required: true description: Minimum visible seconds for a returned pass. schema: type: integer - $ref: '#/components/parameters/ApiKey' responses: '200': description: Visual pass predictions. content: application/json: schema: $ref: '#/components/schemas/VisualPassesResponse' /radiopasses/{id}/{observer_lat}/{observer_lng}/{observer_alt}/{days}/{min_elevation}: get: tags: - Radio Passes summary: Get radio passes description: Predicts radio-communication passes for a satellite. operationId: getRadioPasses parameters: - $ref: '#/components/parameters/SatelliteId' - $ref: '#/components/parameters/ObserverLat' - $ref: '#/components/parameters/ObserverLng' - $ref: '#/components/parameters/ObserverAlt' - name: days in: path required: true description: Days of prediction (max 10). schema: type: integer maximum: 10 - name: min_elevation in: path required: true description: Minimum elevation in degrees. schema: type: integer - $ref: '#/components/parameters/ApiKey' responses: '200': description: Radio pass predictions. content: application/json: schema: $ref: '#/components/schemas/RadioPassesResponse' /above/{observer_lat}/{observer_lng}/{observer_alt}/{search_radius}/{category_id}: get: tags: - Above summary: What's up - satellites overhead description: Returns all satellites within a search radius above an observer. operationId: getAbove parameters: - $ref: '#/components/parameters/ObserverLat' - $ref: '#/components/parameters/ObserverLng' - $ref: '#/components/parameters/ObserverAlt' - name: search_radius in: path required: true description: Search radius in degrees (0-90). schema: type: integer minimum: 0 maximum: 90 - name: category_id in: path required: true description: Satellite category id (0 returns all categories). schema: type: integer - $ref: '#/components/parameters/ApiKey' responses: '200': description: Satellites currently above the observer. content: application/json: schema: $ref: '#/components/schemas/AboveResponse' components: securitySchemes: apiKey: type: apiKey in: query name: apiKey parameters: ApiKey: name: apiKey in: query required: true description: Your N2YO API key. schema: type: string SatelliteId: name: id in: path required: true description: NORAD catalog number for the satellite. schema: type: integer ObserverLat: name: observer_lat in: path required: true description: Observer latitude in decimal degrees. schema: type: number format: float ObserverLng: name: observer_lng in: path required: true description: Observer longitude in decimal degrees. schema: type: number format: float ObserverAlt: name: observer_alt in: path required: true description: Observer altitude in meters above sea level. schema: type: number format: float schemas: SatelliteInfo: type: object properties: satid: type: integer satname: type: string transactionscount: type: integer TLEResponse: type: object properties: info: $ref: '#/components/schemas/SatelliteInfo' tle: type: string description: Two Line Element set for the satellite. Position: type: object properties: satlatitude: type: number satlongitude: type: number sataltitude: type: number azimuth: type: number elevation: type: number ra: type: number dec: type: number timestamp: type: integer eclipsed: type: boolean PositionsResponse: type: object properties: info: $ref: '#/components/schemas/SatelliteInfo' positions: type: array items: $ref: '#/components/schemas/Position' VisualPass: type: object properties: startAz: type: number startAzCompass: type: string startEl: type: number startUTC: type: integer maxAz: type: number maxAzCompass: type: string maxEl: type: number maxUTC: type: integer endAz: type: number endAzCompass: type: string endEl: type: number endUTC: type: integer mag: type: number duration: type: integer VisualPassesResponse: type: object properties: info: allOf: - $ref: '#/components/schemas/SatelliteInfo' - type: object properties: passescount: type: integer passes: type: array items: $ref: '#/components/schemas/VisualPass' RadioPass: type: object properties: startAz: type: number startAzCompass: type: string startUTC: type: integer maxAz: type: number maxAzCompass: type: string maxEl: type: number maxUTC: type: integer endAz: type: number endAzCompass: type: string endUTC: type: integer RadioPassesResponse: type: object properties: info: allOf: - $ref: '#/components/schemas/SatelliteInfo' - type: object properties: passescount: type: integer passes: type: array items: $ref: '#/components/schemas/RadioPass' AboveSatellite: type: object properties: satid: type: integer satname: type: string intDesignator: type: string launchDate: type: string satlat: type: number satlng: type: number satalt: type: number AboveResponse: type: object properties: info: type: object properties: category: type: string transactionscount: type: integer satcount: type: integer above: type: array items: $ref: '#/components/schemas/AboveSatellite'