1
0
mirror of https://github.com/juanfont/headscale.git synced 2025-10-28 10:51:44 +01:00

format protobuf with new settings

Signed-off-by: Kristoffer Dalby <kristoffer@tailscale.com>
This commit is contained in:
Kristoffer Dalby 2024-12-05 09:51:22 +01:00
parent 273483a310
commit 15b26c9231
No known key found for this signature in database
6 changed files with 161 additions and 234 deletions

View File

@ -12,31 +12,18 @@ message ApiKey {
google.protobuf.Timestamp last_seen = 5;
}
message CreateApiKeyRequest {
google.protobuf.Timestamp expiration = 1;
}
message CreateApiKeyRequest { google.protobuf.Timestamp expiration = 1; }
message CreateApiKeyResponse {
string api_key = 1;
}
message CreateApiKeyResponse { string api_key = 1; }
message ExpireApiKeyRequest {
string prefix = 1;
}
message ExpireApiKeyRequest { string prefix = 1; }
message ExpireApiKeyResponse {
}
message ExpireApiKeyResponse {}
message ListApiKeysRequest {
}
message ListApiKeysRequest {}
message ListApiKeysResponse {
repeated ApiKey api_keys = 1;
}
message ListApiKeysResponse { repeated ApiKey api_keys = 1; }
message DeleteApiKeyRequest {
string prefix = 1;
}
message DeleteApiKeyRequest { string prefix = 1; }
message DeleteApiKeyResponse {
}
message DeleteApiKeyResponse {}

View File

@ -29,9 +29,7 @@ message ClientConnectivity {
ClientSupports client_supports = 5;
}
message GetDeviceRequest {
string id = 1;
}
message GetDeviceRequest { string id = 1; }
message GetDeviceResponse {
repeated string addresses = 1;
@ -56,16 +54,11 @@ message GetDeviceResponse {
ClientConnectivity client_connectivity = 20;
}
message DeleteDeviceRequest {
string id = 1;
}
message DeleteDeviceRequest { string id = 1; }
message DeleteDeviceResponse {
}
message DeleteDeviceResponse {}
message GetDeviceRoutesRequest {
string id = 1;
}
message GetDeviceRoutesRequest { string id = 1; }
message GetDeviceRoutesResponse {
repeated string enabled_routes = 1;

View File

@ -55,66 +55,44 @@ message RegisterNodeRequest {
string key = 2;
}
message RegisterNodeResponse {
Node node = 1;
}
message RegisterNodeResponse { Node node = 1; }
message GetNodeRequest {
uint64 node_id = 1;
}
message GetNodeRequest { uint64 node_id = 1; }
message GetNodeResponse {
Node node = 1;
}
message GetNodeResponse { Node node = 1; }
message SetTagsRequest {
uint64 node_id = 1;
repeated string tags = 2;
}
message SetTagsResponse {
Node node = 1;
}
message SetTagsResponse { Node node = 1; }
message DeleteNodeRequest {
uint64 node_id = 1;
}
message DeleteNodeRequest { uint64 node_id = 1; }
message DeleteNodeResponse {}
message ExpireNodeRequest {
uint64 node_id = 1;
}
message ExpireNodeRequest { uint64 node_id = 1; }
message ExpireNodeResponse {
Node node = 1;
}
message ExpireNodeResponse { Node node = 1; }
message RenameNodeRequest {
uint64 node_id = 1;
string new_name = 2;
}
message RenameNodeResponse {
Node node = 1;
}
message RenameNodeResponse { Node node = 1; }
message ListNodesRequest {
string user = 1;
}
message ListNodesRequest { string user = 1; }
message ListNodesResponse {
repeated Node nodes = 1;
}
message ListNodesResponse { repeated Node nodes = 1; }
message MoveNodeRequest {
uint64 node_id = 1;
string user = 2;
}
message MoveNodeResponse {
Node node = 1;
}
message MoveNodeResponse { Node node = 1; }
message DebugCreateNodeRequest {
string user = 1;
@ -123,14 +101,8 @@ message DebugCreateNodeRequest {
repeated string routes = 4;
}
message DebugCreateNodeResponse {
Node node = 1;
}
message DebugCreateNodeResponse { Node node = 1; }
message BackfillNodeIPsRequest {
bool confirmed = 1;
}
message BackfillNodeIPsRequest { bool confirmed = 1; }
message BackfillNodeIPsResponse {
repeated string changes = 1;
}
message BackfillNodeIPsResponse { repeated string changes = 1; }

View File

@ -4,9 +4,7 @@ option go_package = "github.com/juanfont/headscale/gen/go/v1";
import "google/protobuf/timestamp.proto";
message SetPolicyRequest {
string policy = 1;
}
message SetPolicyRequest { string policy = 1; }
message SetPolicyResponse {
string policy = 1;

View File

@ -24,22 +24,15 @@ message CreatePreAuthKeyRequest {
repeated string acl_tags = 5;
}
message CreatePreAuthKeyResponse {
PreAuthKey pre_auth_key = 1;
}
message CreatePreAuthKeyResponse { PreAuthKey pre_auth_key = 1; }
message ExpirePreAuthKeyRequest {
string user = 1;
string key = 2;
}
message ExpirePreAuthKeyResponse {
}
message ExpirePreAuthKeyResponse {}
message ListPreAuthKeysRequest {
string user = 1;
}
message ListPreAuthKeysRequest { string user = 1; }
message ListPreAuthKeysResponse {
repeated PreAuthKey pre_auth_keys = 1;
}
message ListPreAuthKeysResponse { repeated PreAuthKey pre_auth_keys = 1; }

View File

@ -18,38 +18,22 @@ message Route {
google.protobuf.Timestamp deleted_at = 9;
}
message GetRoutesRequest {
}
message GetRoutesRequest {}
message GetRoutesResponse {
repeated Route routes = 1;
}
message GetRoutesResponse { repeated Route routes = 1; }
message EnableRouteRequest {
uint64 route_id = 1;
}
message EnableRouteRequest { uint64 route_id = 1; }
message EnableRouteResponse {
}
message EnableRouteResponse {}
message DisableRouteRequest {
uint64 route_id = 1;
}
message DisableRouteRequest { uint64 route_id = 1; }
message DisableRouteResponse {
}
message DisableRouteResponse {}
message GetNodeRoutesRequest {
uint64 node_id = 1;
}
message GetNodeRoutesRequest { uint64 node_id = 1; }
message GetNodeRoutesResponse {
repeated Route routes = 1;
}
message GetNodeRoutesResponse { repeated Route routes = 1; }
message DeleteRouteRequest {
uint64 route_id = 1;
}
message DeleteRouteRequest { uint64 route_id = 1; }
message DeleteRouteResponse {
}
message DeleteRouteResponse {}