1
0
Fork
You've already forked ripeatlas
0
forked from DNS-OARC/ripeatlas
Go bindings for RIPE Atlas API
  • Go 92.5%
  • Perl 5.1%
  • Makefile 2.4%
2026年03月22日 11:16:33 +01:00
.forgejo/workflows actions 2026年03月22日 11:15:06 +01:00
examples Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
measurement Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
model Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
request Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
.gitignore First implementation of RIPE Atlas API bindings 2017年04月23日 11:02:13 +02:00
atlaser.go Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
file.go Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
go.mod Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
go.sum Traceroute reply 2022年11月07日 09:29:44 +01:00
http.go Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
LICENSE Relicense, funding, actions 2022年11月08日 10:27:14 +01:00
Makefile Traceroute reply 2022年11月07日 09:29:44 +01:00
measurement.go Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
README.md Migrate to Codeberg 2025年09月02日 16:49:05 +02:00
stream.go Migrate to Codeberg 2025年09月02日 16:49:05 +02:00

Go bindings for RIPE Atlas API

GoDoc

About

Go bindings for the RIPE Atlas API to retrieve measurements and other data, can read from JSON files or use the REST API. Will decode the data into Go objects and have helper functions to easily access the data within.

Atlaser

Atlaser is the interface to access RIPE Atlas and there are a few different ways to do so:

  • To read JSON files see File and examples/reader/main.go.
  • To use REST API see Http and examples/reader/main.go.
  • To use Streaming API see Stream and examples/streamer/main.go.

REST API

Implementation status of API calls described by https://atlas.ripe.net/docs/api/v2/reference/ .

anchor-measurements

anchors

credits

keys

measurements

Call Status Func
/api/v2/measurements/ HTTP only Atlaser.Measurements()
/api/v2/measurements/{pk} HTTP only Atlaser.Measurements()
/api/v2/measurements/{pk}/latest/ Done Atlaser.MeasurementLatest()
/api/v2/measurements/{pk}/results/ Done Atlaser.MeasurementResults()

participation-requests

probes

Call Status Func
/api/v2/probes/ HTTP only Atlaser.Probes()
/api/v2/probes/{pk} HTTP only Atlaser.Probes()

Objects

Implementation status of objects (by type) decribed by https://atlas.ripe.net/docs/data_struct/ .

Type Fireware Status
dns 4610 to 4760 Done
ping 4610 to 4760 Done
traceroute 4610 to 4760 Done
http 4610 to 4760 Done
ntp 4610 to 4760 Done
sslcert 4610 to 4760 Done
wifi 4610 to 4760 Done (undocumented by RIPE)

Usage

See or test more complete examples in the examples directory.

import("fmt""codeberg.org/DNS-OARC/ripeatlas")// Read Atlas results from a filea:=ripeatlas.Atlaser(ripeatlas.NewFile())c,err:=a.MeasurementResults(ripeatlas.Params{"file":name})iferr!=nil{...}forr:=rangec{ifr.ParseError!=nil{...}fmt.Printf("%d %s\n",r.MsmId(),r.Type())}// Read Atlas results using REST APIa:=ripeatlas.Atlaser(ripeatlas.NewHttp())c,err:=a.MeasurementResults(ripeatlas.Params{"pk":id})iferr!=nil{...}forr:=rangec{ifr.ParseError!=nil{...}fmt.Printf("%d %s\n",r.MsmId(),r.Type())}// Read DNS measurements using Streaming APIa:=ripeatlas.Atlaser(ripeatlas.NewStream())c,err:=a.MeasurementResults(ripeatlas.Params{"type":"dns"})iferr!=nil{...}forr:=rangec{ifr.ParseError!=nil{...}fmt.Printf("%d %s\n",r.MsmId(),r.Type())}

Author(s)

Jerry Lundström jerry@dns-oarc.net

License

MIT License
Copyright (c) 2022 OARC, Inc.