{"openapi":"3.1.0","info":{"title":"Doppler Effect API","version":"1.0.0","description":"Doppler-effect maths as an API, computed locally and deterministically. The sound endpoint computes the acoustic Doppler shift, f' = f·(v + vo) / (v − vs), where v is the speed of sound (given directly, derived from an air temperature, or the default 343 m/s at 20 °C), vs is the source velocity and vo the observer velocity, with positive velocities meaning approaching: it returns the observed frequency and the frequency shift, and refuses a supersonic source. The light endpoint computes the relativistic Doppler effect for light, f' = f·√((1+β)/(1−β)), from a velocity in metres per second or as a fraction of the speed of light and a direction (approaching blue-shifts, receding red-shifts), returning the frequency and wavelength factor, the observed frequency or wavelength, and the redshift z. The radial-velocity endpoint reverses it: from a measured redshift, or an observed and rest wavelength, it recovers the radial velocity with the exact relativistic relation and the simple v ≈ z·c estimate. Frequencies are in hertz, wavelengths in nanometres, velocities in metres per second. Everything is computed locally and deterministically, so it is instant and private. Ideal for physics and astronomy education, radar, sonar and lidar tools, audio and acoustics apps, and spectroscopy and redshift calculators. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 3 endpoints. This is the Doppler effect; for sound levels and decibels use an acoustics API.","contact":{"name":"PremiumApi","url":"https://www.oanor.com/by/premiumapi"}},"servers":[{"url":"https://api.oanor.com/doppler-api","description":"oanor gateway"}],"tags":[{"name":"Doppler"},{"name":"Meta"}],"components":{"securitySchemes":{"oanorKey":{"type":"apiKey","in":"header","name":"x-oanor-key","description":"Get your key at https://www.oanor.com/developer/keys"}}},"security":[{"oanorKey":[]}],"paths":{"/v1/light":{"get":{"operationId":"get_v1_light","tags":["Doppler"],"summary":"Relativistic light Doppler / redshift","description":"","parameters":[{"name":"velocity","in":"query","required":false,"description":"Relative velocity (m/s)","schema":{"type":"string"}},{"name":"beta","in":"query","required":false,"description":"Or velocity as a fraction of c","schema":{"type":"string"},"example":"0.1"},{"name":"direction","in":"query","required":false,"description":"approaching|receding (default receding)","schema":{"type":"string"},"example":"receding"},{"name":"frequency","in":"query","required":false,"description":"Emitted frequency (optional)","schema":{"type":"string"}},{"name":"wavelength_nm","in":"query","required":false,"description":"Emitted wavelength nm (optional)","schema":{"type":"string"},"example":"656.3"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"Receding source: light is red-shifted (lower frequency, longer wavelength).","formula":"f' = f·√((1+β)/(1−β)); z = λ_obs/λ_emit − 1.","direction":"receding","redshift_z":0.1055416,"velocity_m_s":29979245.8,"frequency_factor":0.90453403,"velocity_fraction_c":0.1,"emitted_wavelength_nm":656.3,"observed_wavelength_nm":725.56694997},"meta":{"timestamp":"2026-06-04T10:18:56.339Z","request_id":"e0fb4486-b9c1-442b-863f-9838ac70588d"},"status":"ok","message":"Relativistic light Doppler / redshift","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/radial-velocity":{"get":{"operationId":"get_v1_radial_velocity","tags":["Doppler"],"summary":"Velocity from a redshift","description":"","parameters":[{"name":"redshift","in":"query","required":false,"description":"Redshift z","schema":{"type":"string"},"example":"0.1"},{"name":"observed_wavelength","in":"query","required":false,"description":"Or observed wavelength","schema":{"type":"string"}},{"name":"rest_wavelength","in":"query","required":false,"description":"And rest wavelength","schema":{"type":"string"}}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"note":"Positive z (red-shift) means receding; negative (blue-shift) means approaching.","formula":"β = ((1+z)² − 1) / ((1+z)² + 1); v = β·c. Non-relativistic: v ≈ z·c.","direction":"receding","redshift_z":0.1,"velocity_m_s":28487066.14,"velocity_km_s":28487.0661,"velocity_fraction_c":0.09502262,"non_relativistic_estimate_km_s":29979.2458},"meta":{"timestamp":"2026-06-04T10:18:56.440Z","request_id":"cfab36cd-b52e-4404-bf50-c77ecbeabca8"},"status":"ok","message":"Velocity from a redshift","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/sound":{"get":{"operationId":"get_v1_sound","tags":["Doppler"],"summary":"Acoustic Doppler shift","description":"","parameters":[{"name":"frequency","in":"query","required":true,"description":"Emitted frequency (Hz)","schema":{"type":"string"},"example":"1000"},{"name":"source_velocity","in":"query","required":false,"description":"Source velocity, + toward observer (m/s)","schema":{"type":"string"},"example":"30"},{"name":"observer_velocity","in":"query","required":false,"description":"Observer velocity, + toward source (m/s)","schema":{"type":"string"}},{"name":"sound_speed","in":"query","required":false,"description":"Speed of sound (m/s)","schema":{"type":"string"}},{"name":"temperature","in":"query","required":false,"description":"Or air temperature (°C) to derive it","schema":{"type":"string"},"example":"20"}],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"formula":"f' = f·(v + vo) / (v − vs); positive velocities mean approaching.","shifted":"higher (approaching)","sound_speed_m_s":343.2146,"frequency_shift_hz":95.780969,"sound_speed_source":"air at 20°C","source_velocity_m_s":30,"emitted_frequency_hz":1000,"observed_frequency_hz":1095.780969,"observer_velocity_m_s":0},"meta":{"timestamp":"2026-06-04T10:18:56.543Z","request_id":"b5bdef9f-03fb-4526-9e55-e52a19ad69af"},"status":"ok","message":"Acoustic Doppler shift","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}},"/v1/meta":{"get":{"operationId":"get_v1_meta","tags":["Meta"],"summary":"Spec","description":"","parameters":[],"security":[{"oanorKey":[]}],"responses":{"200":{"description":"OK","content":{"application/json":{"example":{"data":{"api":"doppler","note":"Doppler-effect maths (acoustic + relativistic) — computed locally and deterministically, no key, no third-party service.","endpoints":["/v1/sound","/v1/light","/v1/radial-velocity","/v1/meta"],"speed_of_light_m_s":299792458,"default_sound_speed_m_s":343},"meta":{"timestamp":"2026-06-04T10:18:56.624Z","request_id":"0acc23e4-6bde-41c8-b5be-2c4c8fc2ef56"},"status":"ok","message":"Meta","success":true}}}},"401":{"description":"Missing or invalid x-oanor-key header"},"402":{"description":"Active subscription required"},"429":{"description":"Rate-limit or monthly quota reached"},"502":{"description":"Upstream did not respond"}}}}},"x-oanor-pricing":[{"slug":"free","name":"Free","price_cents_month":0,"monthly_call_quota":2000,"rps_limit":2,"hard_limit":true},{"slug":"starter","name":"Starter","price_cents_month":500,"monthly_call_quota":25000,"rps_limit":5,"hard_limit":true},{"slug":"pro","name":"Pro","price_cents_month":1500,"monthly_call_quota":150000,"rps_limit":15,"hard_limit":true},{"slug":"mega","name":"Mega","price_cents_month":4900,"monthly_call_quota":786000,"rps_limit":40,"hard_limit":true}],"x-oanor-marketplace-url":"https://www.oanor.com/api/doppler-api"}