Skip to content

Latest commit

 

History

History
137 lines (88 loc) · 3.29 KB

DSourcesApi.md

File metadata and controls

137 lines (88 loc) · 3.29 KB

\DSourcesApi

All URIs are relative to /v1

Method HTTP request Description
GetDsourceById Get /dsources/{dsourceId} Get a dSource by ID.
GetDsources Get /dsources List all dSources.

GetDsourceById

DSource GetDsourceById(ctx, dsourceId).Execute()

Get a dSource by ID.

Example

package main

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

func main() {
    dsourceId := "dsourceId_example" // string | The ID of the dSource.

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

Path Parameters

Name Type Description Notes
ctx context.Context context for authentication, logging, cancellation, deadlines, tracing, etc.
dsourceId string The ID of the dSource.

Other Parameters

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

Name Type Description Notes

Return type

DSource

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]

GetDsources

ListDSourcesResponse GetDsources(ctx).Execute()

List all dSources.

Example

package main

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

func main() {

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

Path Parameters

This endpoint does not need any parameter.

Other Parameters

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

Return type

ListDSourcesResponse

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]