2022-01-25 23:11:15 +01:00
|
|
|
syntax = "proto3";
|
|
|
|
package headscale.v1;
|
2024-12-10 16:23:55 +01:00
|
|
|
option go_package = "github.com/juanfont/headscale/gen/go/v1";
|
2022-01-25 23:11:15 +01:00
|
|
|
|
|
|
|
import "google/protobuf/timestamp.proto";
|
|
|
|
|
|
|
|
message ApiKey {
|
2024-12-10 16:23:55 +01:00
|
|
|
uint64 id = 1;
|
|
|
|
string prefix = 2;
|
|
|
|
google.protobuf.Timestamp expiration = 3;
|
|
|
|
google.protobuf.Timestamp created_at = 4;
|
|
|
|
google.protobuf.Timestamp last_seen = 5;
|
2022-01-25 23:11:15 +01:00
|
|
|
}
|
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message CreateApiKeyRequest { google.protobuf.Timestamp expiration = 1; }
|
2022-01-25 23:11:15 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message CreateApiKeyResponse { string api_key = 1; }
|
2022-01-25 23:11:15 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message ExpireApiKeyRequest { string prefix = 1; }
|
2022-01-25 23:11:15 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message ExpireApiKeyResponse {}
|
2022-01-25 23:11:15 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message ListApiKeysRequest {}
|
2022-01-25 23:11:15 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message ListApiKeysResponse { repeated ApiKey api_keys = 1; }
|
2024-02-12 11:31:21 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message DeleteApiKeyRequest { string prefix = 1; }
|
2024-02-12 11:31:21 +01:00
|
|
|
|
2024-12-10 16:23:55 +01:00
|
|
|
message DeleteApiKeyResponse {}
|