Skip to content

Latest commit

 

History

History
208 lines (130 loc) · 5.48 KB

File metadata and controls

208 lines (130 loc) · 5.48 KB

\BetaAccessAPI

All URIs are relative to https://infrahub-api.nexgencloud.com/v1

Method HTTP request Description
CreateBetaAccessRequest Post /auth/beta-access/requests Create a new beta access request
GetBetaAccessRequests Get /auth/beta-access/requests/{program} Check the status of beta access requests
GetBetaAccessStatus Get /auth/beta-access/requests Check the status of all beta access requests

CreateBetaAccessRequest

BetaAccessRequestResponseModel CreateBetaAccessRequest(ctx).Payload(payload).Execute()

Create a new beta access request

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/NexGenCloud/hyperstack-sdk-go/hyperstack"
)

func main() {
	payload := *openapiclient.NewBetaAccessRequestPayload("Program_example") // BetaAccessRequestPayload | 

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.BetaAccessAPI.CreateBetaAccessRequest(context.Background()).Payload(payload).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `BetaAccessAPI.CreateBetaAccessRequest``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `CreateBetaAccessRequest`: BetaAccessRequestResponseModel
	fmt.Fprintf(os.Stdout, "Response from `BetaAccessAPI.CreateBetaAccessRequest`: %v\n", resp)
}

Path Parameters

Other Parameters

Other parameters are passed through a pointer to a apiCreateBetaAccessRequestRequest struct via the builder pattern

Name Type Description Notes
payload BetaAccessRequestPayload

Return type

BetaAccessRequestResponseModel

Authorization

apiKey

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetBetaAccessRequests

BetaAccessStatusResponseModel GetBetaAccessRequests(ctx, program).Execute()

Check the status of beta access requests

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/NexGenCloud/hyperstack-sdk-go/hyperstack"
)

func main() {
	program := "program_example" // string | 

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.BetaAccessAPI.GetBetaAccessRequests(context.Background(), program).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `BetaAccessAPI.GetBetaAccessRequests``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetBetaAccessRequests`: BetaAccessStatusResponseModel
	fmt.Fprintf(os.Stdout, "Response from `BetaAccessAPI.GetBetaAccessRequests`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
program string

Other Parameters

Other parameters are passed through a pointer to a apiGetBetaAccessRequestsRequest struct via the builder pattern

Name Type Description Notes

Return type

BetaAccessStatusResponseModel

Authorization

apiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]

GetBetaAccessStatus

BetaAccessStatusResponseModel GetBetaAccessStatus(ctx).Execute()

Check the status of all beta access requests

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/NexGenCloud/hyperstack-sdk-go/hyperstack"
)

func main() {

	configuration := openapiclient.NewConfiguration()
	apiClient := openapiclient.NewAPIClient(configuration)
	resp, r, err := apiClient.BetaAccessAPI.GetBetaAccessStatus(context.Background()).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `BetaAccessAPI.GetBetaAccessStatus``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetBetaAccessStatus`: BetaAccessStatusResponseModel
	fmt.Fprintf(os.Stdout, "Response from `BetaAccessAPI.GetBetaAccessStatus`: %v\n", resp)
}

Path Parameters

This endpoint does not need any parameter.

Other Parameters

Other parameters are passed through a pointer to a apiGetBetaAccessStatusRequest struct via the builder pattern

Return type

BetaAccessStatusResponseModel

Authorization

apiKey

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

[Back to top] [Back to API list] [Back to Model list] [Back to README]