Skip to content

puppetlabs/go-cd4pe-client

Repository files navigation

Go API client for cd4pe

API for CD4PE V1

Overview

This API client was generated by the OpenAPI Generator project. By using the OpenAPI-spec from a remote server, you can easily generate an API client.

  • API version: 1.0
  • Package version: 1.0.0
  • Build package: org.openapitools.codegen.languages.GoClientCodegen

Installation

Install the following dependencies:

go get github.com/stretchr/testify/assert
go get golang.org/x/oauth2
go get golang.org/x/net/context
go get github.com/antihax/optional

Put the package under your project folder and add the following in import:

import "./cd4pe"

Documentation for API Endpoints

All URIs are relative to http://localhost/api/v1

Class Method HTTP request Description
DefaultApi CreateToken Post /auth/token Create a token associated with the passed in credentials
DefaultApi EvaluatePermissions Post /permitted Evaluate permissions for a user
DefaultApi GetControlRepos Get /workspaces/{workspaceId}/controlrepos
DefaultApi GetUserInfo Get /user Get information about the user associated with this token
DefaultApi ListPeIntegrationsWithToken Get /internal/workspaces/{workspaceId}/integrations/pe List PE integrations for a workspace

Documentation For Models

Documentation For Authorization

default

  • Type: API key

Example

auth := context.WithValue(context.Background(), sw.ContextAPIKey, sw.APIKey{
    Key: "APIKEY",
    Prefix: "Bearer", // Omit if not necessary.
})
r, err := client.Service.Operation(auth, args)

Author

About

A CD4PE client generated from swagger

Resources

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published