Files
openapi-go-answer/docs/PluginConnectorAPI.md
2023-09-26 16:20:01 +08:00

7.9 KiB

\PluginConnectorAPI

All URIs are relative to http://localhost

Method HTTP request Description
AnswerApiV1ConnectorBindingEmailPost Post /answer/api/v1/connector/binding/email external login binding user send email
AnswerApiV1ConnectorInfoGet Get /answer/api/v1/connector/info get all enabled connectors
AnswerApiV1ConnectorUserInfoGet Get /answer/api/v1/connector/user/info get all connectors info about user
AnswerApiV1ConnectorUserUnbindingDelete Delete /answer/api/v1/connector/user/unbinding unbind external user login

AnswerApiV1ConnectorBindingEmailPost

AnswerApiV1ConnectorBindingEmailPost200Response AnswerApiV1ConnectorBindingEmailPost(ctx).Data(data).Execute()

external login binding user send email

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "git.ncc.cx/package/openapi-go-answer"
)

func main() {
    data := *openapiclient.NewSchemaExternalLoginBindingUserSendEmailReq("BindingKey_example", "Email_example") // SchemaExternalLoginBindingUserSendEmailReq | external login binding user send email

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

Path Parameters

Other Parameters

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

Name Type Description Notes
data SchemaExternalLoginBindingUserSendEmailReq external login binding user send email

Return type

AnswerApiV1ConnectorBindingEmailPost200Response

Authorization

No authorization required

HTTP request headers

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

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

AnswerApiV1ConnectorInfoGet

AnswerApiV1ConnectorInfoGet200Response AnswerApiV1ConnectorInfoGet(ctx).Execute()

get all enabled connectors

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "git.ncc.cx/package/openapi-go-answer"
)

func main() {

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

Path Parameters

This endpoint does not need any parameter.

Other Parameters

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

Return type

AnswerApiV1ConnectorInfoGet200Response

Authorization

ApiKeyAuth

HTTP request headers

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

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

AnswerApiV1ConnectorUserInfoGet

AnswerApiV1ConnectorUserInfoGet200Response AnswerApiV1ConnectorUserInfoGet(ctx).Execute()

get all connectors info about user

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "git.ncc.cx/package/openapi-go-answer"
)

func main() {

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

Path Parameters

This endpoint does not need any parameter.

Other Parameters

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

Return type

AnswerApiV1ConnectorUserInfoGet200Response

Authorization

ApiKeyAuth

HTTP request headers

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

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

AnswerApiV1ConnectorUserUnbindingDelete

HandlerRespBody AnswerApiV1ConnectorUserUnbindingDelete(ctx).Data(data).Execute()

unbind external user login

Example

package main

import (
    "context"
    "fmt"
    "os"
    openapiclient "git.ncc.cx/package/openapi-go-answer"
)

func main() {
    data := *openapiclient.NewSchemaExternalLoginUnbindingReq("ExternalId_example") // SchemaExternalLoginUnbindingReq | ExternalLoginUnbindingReq

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

Path Parameters

Other Parameters

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

Name Type Description Notes
data SchemaExternalLoginUnbindingReq ExternalLoginUnbindingReq

Return type

HandlerRespBody

Authorization

ApiKeyAuth

HTTP request headers

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

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