Skip to content

Latest commit

 

History

History
438 lines (294 loc) · 17.4 KB

File metadata and controls

438 lines (294 loc) · 17.4 KB

\UserApi

All URIs are relative to http://keyfactor.example.com

Method HTTP request Description
CreateSSHUsers POST /SSH/Users Creates a new SSH User.
CreateSSHUsersAccess POST /SSH/Users/Access Updates logon access for a user
DeleteSSHUsersById DELETE /SSH/Users/{id} Deletes an SSH user.
GetSSHUsers GET /SSH/Users Returns users matching the criteria from the provided query parameters
GetSSHUsersById GET /SSH/Users/{id} Looks up information about an existing SSH user.
UpdateSSHUsers PUT /SSH/Users Updates information about a given user.

CreateSSHUsers

CSSCMSDataModelModelsSSHUsersSshUserResponse NewCreateSSHUsersRequest(ctx).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).CSSCMSDataModelModelsSSHUsersSshUserCreationRequest(cSSCMSDataModelModelsSSHUsersSshUserCreationRequest).Execute()

Creates a new SSH User.

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    xKeyfactorRequestedWith := "APIClient" // string | Type of the request [XMLHttpRequest, APIClient]
    xKeyfactorApiVersion := "1.0" // string | Desired version of the api, if not provided defaults to v1 (optional)
    cSSCMSDataModelModelsSSHUsersSshUserCreationRequest := *openapiclient.NewCSSCMSDataModelModelsSSHUsersSshUserCreationRequest("Username_example") // CSSCMSDataModelModelsSSHUsersSshUserCreationRequest | SSH user to be created. (optional)

    configuration := openapiclient.NewConfiguration(make(map[string]string))
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.UserApi.NewCreateSSHUsersRequest(context.Background()).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).CSSCMSDataModelModelsSSHUsersSshUserCreationRequest(cSSCMSDataModelModelsSSHUsersSshUserCreationRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `UserApi.CreateSSHUsers``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `CreateSSHUsers`: CSSCMSDataModelModelsSSHUsersSshUserResponse
    fmt.Fprintf(os.Stdout, "Response from `UserApi.CreateSSHUsers`: %v\n", resp)
}

Path Parameters

Other Parameters

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

Name Type Description Notes
xKeyfactorRequestedWith string Type of the request [XMLHttpRequest, APIClient]
xKeyfactorApiVersion string Desired version of the api, if not provided defaults to v1
cSSCMSDataModelModelsSSHUsersSshUserCreationRequest CSSCMSDataModelModelsSSHUsersSshUserCreationRequest SSH user to be created.

Return type

CSSCMSDataModelModelsSSHUsersSshUserResponse

Authorization

basicAuth

HTTP request headers

  • Content-Type: application/json-patch+json, application/json, text/json, application/*+json
  • Accept: text/plain, application/json, text/json

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

CreateSSHUsersAccess

CSSCMSDataModelModelsSSHUsersSshUserAccessResponse NewCreateSSHUsersAccessRequest(ctx).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest(cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest).Execute()

Updates logon access for a user

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    xKeyfactorRequestedWith := "APIClient" // string | Type of the request [XMLHttpRequest, APIClient]
    xKeyfactorApiVersion := "1.0" // string | Desired version of the api, if not provided defaults to v1 (optional)
    cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest := *openapiclient.NewCSSCMSDataModelModelsSSHUsersSshUserUpdateRequest(int32(123)) // CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest | Logons to add the existing user (optional)

    configuration := openapiclient.NewConfiguration(make(map[string]string))
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.UserApi.NewCreateSSHUsersAccessRequest(context.Background()).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest(cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `UserApi.CreateSSHUsersAccess``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `CreateSSHUsersAccess`: CSSCMSDataModelModelsSSHUsersSshUserAccessResponse
    fmt.Fprintf(os.Stdout, "Response from `UserApi.CreateSSHUsersAccess`: %v\n", resp)
}

Path Parameters

Other Parameters

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

Name Type Description Notes
xKeyfactorRequestedWith string Type of the request [XMLHttpRequest, APIClient]
xKeyfactorApiVersion string Desired version of the api, if not provided defaults to v1
cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest Logons to add the existing user

Return type

CSSCMSDataModelModelsSSHUsersSshUserAccessResponse

Authorization

basicAuth

HTTP request headers

  • Content-Type: application/json-patch+json, application/json, text/json, application/*+json
  • Accept: text/plain, application/json, text/json

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

DeleteSSHUsersById

NewDeleteSSHUsersByIdRequest(ctx, id).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).Execute()

Deletes an SSH user.

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    id := int32(56) // int32 | The Id of the user to delete.
    xKeyfactorRequestedWith := "APIClient" // string | Type of the request [XMLHttpRequest, APIClient]
    xKeyfactorApiVersion := "1.0" // string | Desired version of the api, if not provided defaults to v1 (optional)

    configuration := openapiclient.NewConfiguration(make(map[string]string))
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.UserApi.NewDeleteSSHUsersByIdRequest(context.Background(), id).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `UserApi.DeleteSSHUsersById``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
id int32 The Id of the user to delete.

Other Parameters

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

Name Type Description Notes

xKeyfactorRequestedWith | string | Type of the request [XMLHttpRequest, APIClient] | xKeyfactorApiVersion | string | Desired version of the api, if not provided defaults to v1 |

Return type

(empty response body)

Authorization

basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: Not defined

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

GetSSHUsers

[]CSSCMSDataModelModelsSSHUsersSshUserResponse NewGetSSHUsersRequest(ctx).XKeyfactorRequestedWith(xKeyfactorRequestedWith).QueryString(queryString).PageReturned(pageReturned).ReturnLimit(returnLimit).SortField(sortField).SortAscending(sortAscending).ShowOwnedAccess(showOwnedAccess).XKeyfactorApiVersion(xKeyfactorApiVersion).Execute()

Returns users matching the criteria from the provided query parameters

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    xKeyfactorRequestedWith := "APIClient" // string | Type of the request [XMLHttpRequest, APIClient]
    queryString := "queryString_example" // string |  (optional)
    pageReturned := int32(56) // int32 |  (optional)
    returnLimit := int32(56) // int32 |  (optional)
    sortField := "sortField_example" // string |  (optional)
    sortAscending := openapiclient.Keyfactor.Common.QueryableExtensions.SortOrder(0) // KeyfactorCommonQueryableExtensionsSortOrder |  (optional)
    showOwnedAccess := true // bool | Whether or not to return only logons that have access to servers the requesting user owns (optional) (default to false)
    xKeyfactorApiVersion := "1.0" // string | Desired version of the api, if not provided defaults to v1 (optional)

    configuration := openapiclient.NewConfiguration(make(map[string]string))
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.UserApi.NewGetSSHUsersRequest(context.Background()).XKeyfactorRequestedWith(xKeyfactorRequestedWith).QueryString(queryString).PageReturned(pageReturned).ReturnLimit(returnLimit).SortField(sortField).SortAscending(sortAscending).ShowOwnedAccess(showOwnedAccess).XKeyfactorApiVersion(xKeyfactorApiVersion).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `UserApi.GetSSHUsers``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `GetSSHUsers`: []CSSCMSDataModelModelsSSHUsersSshUserResponse
    fmt.Fprintf(os.Stdout, "Response from `UserApi.GetSSHUsers`: %v\n", resp)
}

Path Parameters

Other Parameters

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

Name Type Description Notes
xKeyfactorRequestedWith string Type of the request [XMLHttpRequest, APIClient]
queryString string
pageReturned int32
returnLimit int32
sortField string
sortAscending KeyfactorCommonQueryableExtensionsSortOrder
showOwnedAccess bool Whether or not to return only logons that have access to servers the requesting user owns [default to false]
xKeyfactorApiVersion string Desired version of the api, if not provided defaults to v1

Return type

[]CSSCMSDataModelModelsSSHUsersSshUserResponse

Authorization

basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: text/plain, application/json, text/json

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

GetSSHUsersById

CSSCMSDataModelModelsSSHUsersSshUserResponse NewGetSSHUsersByIdRequest(ctx, id).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).Execute()

Looks up information about an existing SSH user.

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    id := int32(56) // int32 | The Id of the SSH user to retrieve.
    xKeyfactorRequestedWith := "APIClient" // string | Type of the request [XMLHttpRequest, APIClient]
    xKeyfactorApiVersion := "1.0" // string | Desired version of the api, if not provided defaults to v1 (optional)

    configuration := openapiclient.NewConfiguration(make(map[string]string))
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.UserApi.NewGetSSHUsersByIdRequest(context.Background(), id).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `UserApi.GetSSHUsersById``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `GetSSHUsersById`: CSSCMSDataModelModelsSSHUsersSshUserResponse
    fmt.Fprintf(os.Stdout, "Response from `UserApi.GetSSHUsersById`: %v\n", resp)
}

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
id int32 The Id of the SSH user to retrieve.

Other Parameters

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

Name Type Description Notes

xKeyfactorRequestedWith | string | Type of the request [XMLHttpRequest, APIClient] | xKeyfactorApiVersion | string | Desired version of the api, if not provided defaults to v1 |

Return type

CSSCMSDataModelModelsSSHUsersSshUserResponse

Authorization

basicAuth

HTTP request headers

  • Content-Type: Not defined
  • Accept: text/plain, application/json, text/json

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

UpdateSSHUsers

CSSCMSDataModelModelsSSHUsersSshUserResponse NewUpdateSSHUsersRequest(ctx).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest(cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest).Execute()

Updates information about a given user.

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "./openapi"
)

func main() {
    xKeyfactorRequestedWith := "APIClient" // string | Type of the request [XMLHttpRequest, APIClient]
    xKeyfactorApiVersion := "1.0" // string | Desired version of the api, if not provided defaults to v1 (optional)
    cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest := *openapiclient.NewCSSCMSDataModelModelsSSHUsersSshUserUpdateRequest(int32(123)) // CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest | The new state of the SSH user to update. (optional)

    configuration := openapiclient.NewConfiguration(make(map[string]string))
    apiClient := openapiclient.NewAPIClient(configuration)
    resp, r, err := apiClient.UserApi.NewUpdateSSHUsersRequest(context.Background()).XKeyfactorRequestedWith(xKeyfactorRequestedWith).XKeyfactorApiVersion(xKeyfactorApiVersion).CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest(cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest).Execute()
    if err != nil {
        fmt.Fprintf(os.Stderr, "Error when calling `UserApi.UpdateSSHUsers``: %v\n", err)
        fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
    }
    // response from `UpdateSSHUsers`: CSSCMSDataModelModelsSSHUsersSshUserResponse
    fmt.Fprintf(os.Stdout, "Response from `UserApi.UpdateSSHUsers`: %v\n", resp)
}

Path Parameters

Other Parameters

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

Name Type Description Notes
xKeyfactorRequestedWith string Type of the request [XMLHttpRequest, APIClient]
xKeyfactorApiVersion string Desired version of the api, if not provided defaults to v1
cSSCMSDataModelModelsSSHUsersSshUserUpdateRequest CSSCMSDataModelModelsSSHUsersSshUserUpdateRequest The new state of the SSH user to update.

Return type

CSSCMSDataModelModelsSSHUsersSshUserResponse

Authorization

basicAuth

HTTP request headers

  • Content-Type: application/json-patch+json, application/json, text/json, application/*+json
  • Accept: text/plain, application/json, text/json

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