syntax = "proto3";

// If you make any changes make sure you run: make regenerate-proto

package gitlab.agent.gitlab_access.rpc;

option go_package = "gitlab.com/gitlab-org/cluster-integration/gitlab-agent/v18/internal/module/gitlab_access/rpc";

import "internal/tool/grpctool/grpctool.proto";
import "buf/validate/validate.proto";

// HeaderExtra is passed in grpctool.HttpRequest.extra.
message HeaderExtra {
    // Name of the module that is making the request.
    string module_name = 1 [(buf.validate.field).string.min_bytes = 1];
}

service GitlabAccess {
  // MakeRequest allows to make a HTTP request to GitLab internal API for modules.
  rpc MakeRequest (stream grpctool.HttpRequest) returns (stream grpctool.HttpResponse) {
  }
}
