Documentation
¶
Overview ¶
Package workflows provides the CyberArk Access Requests API client.
Index ¶
- func ServiceConfig() services.IdsecServiceConfig
- type AccessRequestService
- func (s *AccessRequestService) CancelRequest(ctx context.Context, requestID string, reason *string) (*models.AccessRequest, error)
- func (s *AccessRequestService) FinalizeRequest(ctx context.Context, requestID, result string, reason *string) (*models.AccessRequest, error)
- func (s *AccessRequestService) GetRequest(ctx context.Context, requestID string) (*models.AccessRequest, error)
- func (s *AccessRequestService) GetRequestForms(ctx context.Context, targetCategory, requestType string) (*models.RequestFormResponse, error)
- func (s *AccessRequestService) ListRequests(ctx context.Context, params ListRequestsParams) ([]models.AccessRequest, int, error)
- func (s *AccessRequestService) ServiceConfig() services.IdsecServiceConfig
- func (s *AccessRequestService) SubmitRequest(ctx context.Context, req *models.SubmitAccessRequest) (*models.AccessRequest, error)
- type ListRequestsParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ServiceConfig ¶
func ServiceConfig() services.IdsecServiceConfig
ServiceConfig returns the configuration for the Access Requests Service. It specifies the service name "access-requests" and requires the "isp" authenticator.
Types ¶
type AccessRequestService ¶
type AccessRequestService struct {
services.IdsecService
*services.IdsecBaseService
// contains filtered or unexported fields
}
AccessRequestService provides access to the Access Requests API endpoints.
func NewAccessRequestService ¶
func NewAccessRequestService(authenticators ...auth.IdsecAuth) (*AccessRequestService, error)
NewAccessRequestService creates a new Access Request Service instance.
func NewAccessRequestServiceWithClient ¶
func NewAccessRequestServiceWithClient(client httpClient) *AccessRequestService
NewAccessRequestServiceWithClient creates a service with a custom HTTP client for testing.
func (*AccessRequestService) CancelRequest ¶
func (s *AccessRequestService) CancelRequest(ctx context.Context, requestID string, reason *string) (*models.AccessRequest, error)
CancelRequest cancels an open access request. POST /api/workflows/requests/{requestId}/cancel
func (*AccessRequestService) FinalizeRequest ¶
func (s *AccessRequestService) FinalizeRequest(ctx context.Context, requestID, result string, reason *string) (*models.AccessRequest, error)
FinalizeRequest approves or rejects an access request. POST /api/workflows/requests/{requestId}/finalize
func (*AccessRequestService) GetRequest ¶
func (s *AccessRequestService) GetRequest(ctx context.Context, requestID string) (*models.AccessRequest, error)
GetRequest retrieves a single access request by ID. GET /api/workflows/requests/{requestId}
func (*AccessRequestService) GetRequestForms ¶
func (s *AccessRequestService) GetRequestForms(ctx context.Context, targetCategory, requestType string) (*models.RequestFormResponse, error)
GetRequestForms retrieves the access request form structure. GET /api/workflows/request-forms
func (*AccessRequestService) ListRequests ¶
func (s *AccessRequestService) ListRequests(ctx context.Context, params ListRequestsParams) ([]models.AccessRequest, int, error)
ListRequests retrieves all access requests matching the given parameters, fetching all pages via offset/limit pagination. GET /api/workflows/requests
func (*AccessRequestService) ServiceConfig ¶
func (s *AccessRequestService) ServiceConfig() services.IdsecServiceConfig
ServiceConfig returns the service configuration.
func (*AccessRequestService) SubmitRequest ¶
func (s *AccessRequestService) SubmitRequest(ctx context.Context, req *models.SubmitAccessRequest) (*models.AccessRequest, error)
SubmitRequest creates a new access request. POST /api/workflows/requests