Skip to content

Latest commit

 

History

History
1036 lines (672 loc) · 31.3 KB

File metadata and controls

1036 lines (672 loc) · 31.3 KB

CollectionsAPI

All URIs are relative to https://api.reveng.ai

Method HTTP request Description
CreateCollection Post /v2/collections Creates new collection information
DeleteCollection Delete /v2/collections/{collection_id} Deletes a collection
GetCollection Get /v2/collections/{collection_id} Returns a collection
ListCollections Get /v2/collections Gets basic collections information
UpdateCollection Patch /v2/collections/{collection_id} Updates a collection
UpdateCollectionBinaries Patch /v2/collections/{collection_id}/binaries Updates a collection binaries
UpdateCollectionTags Patch /v2/collections/{collection_id}/tags Updates a collection tags
V3CreateCollection Post /v3/collections Create a collection.
V3DeleteCollection Delete /v3/collections/{collection_id} Delete a collection.
V3GetCollection Get /v3/collections/{collection_id} Get a collection.
V3ListCollections Get /v3/collections List collections.
V3PatchCollection Patch /v3/collections/{collection_id} Update a collection.
V3PatchCollectionBinaries Patch /v3/collections/{collection_id}/binaries Replace the binaries in a collection.
V3PatchCollectionTags Patch /v3/collections/{collection_id}/tags Replace the tags on a collection.

CreateCollection

BaseResponseCollectionResponse CreateCollection(ctx).CollectionCreateRequest(collectionCreateRequest).Execute()

Creates new collection information

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionCreateRequest := *revengai.NewCollectionCreateRequest("CollectionName_example", "Description_example", int32(123)) // CollectionCreateRequest | 

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

Path Parameters

Other Parameters

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

Name Type Description Notes
collectionCreateRequest CollectionCreateRequest

Return type

BaseResponseCollectionResponse

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

DeleteCollection

BaseResponseBool DeleteCollection(ctx, collectionId).Execute()

Deletes a collection

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int32(56) // int32 | 

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

Path Parameters

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

Other Parameters

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

Name Type Description Notes

Return type

BaseResponseBool

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

GetCollection

BaseResponseCollectionResponse GetCollection(ctx, collectionId).IncludeTags(includeTags).IncludeBinaries(includeBinaries).PageSize(pageSize).PageNumber(pageNumber).BinarySearchStr(binarySearchStr).Execute()

Returns a collection

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int32(56) // int32 | 
	includeTags := true // bool |  (optional) (default to false)
	includeBinaries := true // bool |  (optional) (default to false)
	pageSize := int32(56) // int32 |  (optional) (default to 10)
	pageNumber := int32(56) // int32 |  (optional) (default to 1)
	binarySearchStr := "binarySearchStr_example" // string |  (optional)

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.GetCollection(context.Background(), collectionId).IncludeTags(includeTags).IncludeBinaries(includeBinaries).PageSize(pageSize).PageNumber(pageNumber).BinarySearchStr(binarySearchStr).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.GetCollection``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `GetCollection`: BaseResponseCollectionResponse
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.GetCollection`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

includeTags | bool | | [default to false] includeBinaries | bool | | [default to false] pageSize | int32 | | [default to 10] pageNumber | int32 | | [default to 1] binarySearchStr | string | |

Return type

BaseResponseCollectionResponse

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

ListCollections

BaseResponseListCollectionResults ListCollections(ctx).SearchTerm(searchTerm).Filters(filters).Limit(limit).Offset(offset).OrderBy(orderBy).Order(order).Execute()

Gets basic collections information

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	searchTerm := "searchTerm_example" // string |  (optional) (default to "")
	filters := []revengai.Filters{revengai.Filters("official_only")} // []Filters |  (optional) (default to {})
	limit := int32(56) // int32 |  (optional) (default to 20)
	offset := int32(56) // int32 |  (optional) (default to 0)
	orderBy := revengai.app__api__rest__v2__collections__enums__OrderBy("created") // AppApiRestV2CollectionsEnumsOrderBy |  (optional) (default to "collection")
	order := revengai.Order("ASC") // Order |  (optional) (default to "ASC")

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.ListCollections(context.Background()).SearchTerm(searchTerm).Filters(filters).Limit(limit).Offset(offset).OrderBy(orderBy).Order(order).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.ListCollections``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `ListCollections`: BaseResponseListCollectionResults
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.ListCollections`: %v\n", resp)
}

Path Parameters

Other Parameters

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

Name Type Description Notes
searchTerm string [default to ""]
filters []Filters [default to {}]
limit int32 [default to 20]
offset int32 [default to 0]
orderBy AppApiRestV2CollectionsEnumsOrderBy [default to "collection"]
order Order [default to "ASC"]

Return type

BaseResponseListCollectionResults

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

UpdateCollection

BaseResponseCollectionResponse UpdateCollection(ctx, collectionId).CollectionUpdateRequest(collectionUpdateRequest).Execute()

Updates a collection

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int32(56) // int32 | 
	collectionUpdateRequest := *revengai.NewCollectionUpdateRequest() // CollectionUpdateRequest | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.UpdateCollection(context.Background(), collectionId).CollectionUpdateRequest(collectionUpdateRequest).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.UpdateCollection``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `UpdateCollection`: BaseResponseCollectionResponse
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.UpdateCollection`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

collectionUpdateRequest | CollectionUpdateRequest | |

Return type

BaseResponseCollectionResponse

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

UpdateCollectionBinaries

BaseResponseCollectionBinariesUpdateResponse UpdateCollectionBinaries(ctx, collectionId).CollectionBinariesUpdateRequest(collectionBinariesUpdateRequest).Execute()

Updates a collection binaries

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int32(56) // int32 | 
	collectionBinariesUpdateRequest := *revengai.NewCollectionBinariesUpdateRequest([]int32{int32(123)}) // CollectionBinariesUpdateRequest | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.UpdateCollectionBinaries(context.Background(), collectionId).CollectionBinariesUpdateRequest(collectionBinariesUpdateRequest).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.UpdateCollectionBinaries``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `UpdateCollectionBinaries`: BaseResponseCollectionBinariesUpdateResponse
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.UpdateCollectionBinaries`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

collectionBinariesUpdateRequest | CollectionBinariesUpdateRequest | |

Return type

BaseResponseCollectionBinariesUpdateResponse

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

UpdateCollectionTags

BaseResponseCollectionTagsUpdateResponse UpdateCollectionTags(ctx, collectionId).CollectionTagsUpdateRequest(collectionTagsUpdateRequest).Execute()

Updates a collection tags

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int32(56) // int32 | 
	collectionTagsUpdateRequest := *revengai.NewCollectionTagsUpdateRequest([]string{"Tags_example"}) // CollectionTagsUpdateRequest | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.UpdateCollectionTags(context.Background(), collectionId).CollectionTagsUpdateRequest(collectionTagsUpdateRequest).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.UpdateCollectionTags``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `UpdateCollectionTags`: BaseResponseCollectionTagsUpdateResponse
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.UpdateCollectionTags`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

collectionTagsUpdateRequest | CollectionTagsUpdateRequest | |

Return type

BaseResponseCollectionTagsUpdateResponse

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3CreateCollection

CreateCollectionOutputBody V3CreateCollection(ctx).CreateCollectionInputBody(createCollectionInputBody).Execute()

Create a collection.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	createCollectionInputBody := *revengai.NewCreateCollectionInputBody("CollectionName_example", "CollectionScope_example", "Description_example", int64(123)) // CreateCollectionInputBody | 

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

Path Parameters

Other Parameters

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

Name Type Description Notes
createCollectionInputBody CreateCollectionInputBody

Return type

CreateCollectionOutputBody

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3DeleteCollection

V3DeleteCollection(ctx, collectionId).Execute()

Delete a collection.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int64(789) // int64 | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	r, err := apiClient.CollectionsAPI.V3DeleteCollection(context.Background(), collectionId).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.V3DeleteCollection``: %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.
collectionId int64

Other Parameters

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

Name Type Description Notes

Return type

(empty response body)

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3GetCollection

GetCollectionOutputBody V3GetCollection(ctx, collectionId).IncludeTags(includeTags).IncludeBinaries(includeBinaries).PageSize(pageSize).PageNumber(pageNumber).BinarySearchStr(binarySearchStr).Execute()

Get a collection.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int64(789) // int64 | 
	includeTags := true // bool |  (optional)
	includeBinaries := true // bool |  (optional)
	pageSize := int64(789) // int64 |  (optional) (default to 10)
	pageNumber := int64(789) // int64 |  (optional) (default to 1)
	binarySearchStr := "binarySearchStr_example" // string |  (optional)

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.V3GetCollection(context.Background(), collectionId).IncludeTags(includeTags).IncludeBinaries(includeBinaries).PageSize(pageSize).PageNumber(pageNumber).BinarySearchStr(binarySearchStr).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.V3GetCollection``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `V3GetCollection`: GetCollectionOutputBody
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.V3GetCollection`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

includeTags | bool | | includeBinaries | bool | | pageSize | int64 | | [default to 10] pageNumber | int64 | | [default to 1] binarySearchStr | string | |

Return type

GetCollectionOutputBody

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3ListCollections

ListCollectionsOutputBody V3ListCollections(ctx).SearchTerm(searchTerm).Filters(filters).Limit(limit).Offset(offset).OrderBy(orderBy).Order(order).Execute()

List collections.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	searchTerm := "searchTerm_example" // string |  (optional)
	filters := []string{"Filters_example"} // []string |  (optional)
	limit := int64(789) // int64 |  (optional) (default to 20)
	offset := int64(789) // int64 |  (optional) (default to 0)
	orderBy := "orderBy_example" // string |  (optional) (default to "collection")
	order := "order_example" // string |  (optional) (default to "ASC")

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.V3ListCollections(context.Background()).SearchTerm(searchTerm).Filters(filters).Limit(limit).Offset(offset).OrderBy(orderBy).Order(order).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.V3ListCollections``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `V3ListCollections`: ListCollectionsOutputBody
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.V3ListCollections`: %v\n", resp)
}

Path Parameters

Other Parameters

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

Name Type Description Notes
searchTerm string
filters []string
limit int64 [default to 20]
offset int64 [default to 0]
orderBy string [default to "collection"]
order string [default to "ASC"]

Return type

ListCollectionsOutputBody

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3PatchCollection

PatchCollectionOutputBody V3PatchCollection(ctx, collectionId).PatchCollectionInputBody(patchCollectionInputBody).Execute()

Update a collection.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int64(789) // int64 | 
	patchCollectionInputBody := *revengai.NewPatchCollectionInputBody() // PatchCollectionInputBody | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.V3PatchCollection(context.Background(), collectionId).PatchCollectionInputBody(patchCollectionInputBody).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.V3PatchCollection``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `V3PatchCollection`: PatchCollectionOutputBody
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.V3PatchCollection`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

patchCollectionInputBody | PatchCollectionInputBody | |

Return type

PatchCollectionOutputBody

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3PatchCollectionBinaries

PatchCollectionBinariesOutputBody V3PatchCollectionBinaries(ctx, collectionId).PatchCollectionBinariesInputBody(patchCollectionBinariesInputBody).Execute()

Replace the binaries in a collection.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int64(789) // int64 | 
	patchCollectionBinariesInputBody := *revengai.NewPatchCollectionBinariesInputBody([]int64{int64(123)}) // PatchCollectionBinariesInputBody | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.V3PatchCollectionBinaries(context.Background(), collectionId).PatchCollectionBinariesInputBody(patchCollectionBinariesInputBody).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.V3PatchCollectionBinaries``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `V3PatchCollectionBinaries`: PatchCollectionBinariesOutputBody
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.V3PatchCollectionBinaries`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

patchCollectionBinariesInputBody | PatchCollectionBinariesInputBody | |

Return type

PatchCollectionBinariesOutputBody

Authorization

APIKey, bearerAuth

HTTP request headers

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

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

V3PatchCollectionTags

PatchCollectionTagsOutputBody V3PatchCollectionTags(ctx, collectionId).PatchCollectionTagsInputBody(patchCollectionTagsInputBody).Execute()

Replace the tags on a collection.

Example

package main

import (
	"context"
	"fmt"
	"os"
	revengai "github.com/RevEngAI/sdk-go/v3"
)

func main() {
	collectionId := int64(789) // int64 | 
	patchCollectionTagsInputBody := *revengai.NewPatchCollectionTagsInputBody([]string{"Tags_example"}) // PatchCollectionTagsInputBody | 

	configuration := revengai.NewConfiguration()
	apiClient := revengai.NewAPIClient(configuration)
	resp, r, err := apiClient.CollectionsAPI.V3PatchCollectionTags(context.Background(), collectionId).PatchCollectionTagsInputBody(patchCollectionTagsInputBody).Execute()
	if err != nil {
		fmt.Fprintf(os.Stderr, "Error when calling `CollectionsAPI.V3PatchCollectionTags``: %v\n", err)
		fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
	}
	// response from `V3PatchCollectionTags`: PatchCollectionTagsOutputBody
	fmt.Fprintf(os.Stdout, "Response from `CollectionsAPI.V3PatchCollectionTags`: %v\n", resp)
}

Path Parameters

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

Other Parameters

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

Name Type Description Notes

patchCollectionTagsInputBody | PatchCollectionTagsInputBody | |

Return type

PatchCollectionTagsOutputBody

Authorization

APIKey, bearerAuth

HTTP request headers

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

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