\IndexAPI

February 16, 2026 ยท View on GitHub

All URIs are relative to http://127.0.0.1:9308

MethodHTTP requestDescription
BulkPost /bulkBulk table operations
DeletePost /deleteDelete a document in a table
InsertPost /insertCreate a new document in a table
PartialReplacePost /{table}/_update/{id}Partially replaces a document in a table
ReplacePost /replaceReplace new document in a table
UpdatePost /updateUpdate a document in a table

Bulk

BulkResponse Bulk(ctx).Body(body).Execute()

Bulk table operations

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/manticoresoftware/manticoresearch-go"
)

func main() {
	body := "body_example" // string | 

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

Path Parameters

Other Parameters

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

NameTypeDescriptionNotes
bodystring

Return type

BulkResponse

Authorization

No authorization required

HTTP request headers

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

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

Delete

DeleteResponse Delete(ctx).DeleteDocumentRequest(deleteDocumentRequest).Execute()

Delete a document in a table

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/manticoresoftware/manticoresearch-go"
)

func main() {
	deleteDocumentRequest := *openapiclient.NewDeleteDocumentRequest("Table_example") // DeleteDocumentRequest | 

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

Path Parameters

Other Parameters

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

NameTypeDescriptionNotes
deleteDocumentRequestDeleteDocumentRequest

Return type

DeleteResponse

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]

Insert

SuccessResponse Insert(ctx).InsertDocumentRequest(insertDocumentRequest).Execute()

Create a new document in a table

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/manticoresoftware/manticoresearch-go"
)

func main() {
	insertDocumentRequest := *openapiclient.NewInsertDocumentRequest("Table_example", map[string]interface{}(123)) // InsertDocumentRequest | 

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

Path Parameters

Other Parameters

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

NameTypeDescriptionNotes
insertDocumentRequestInsertDocumentRequest

Return type

SuccessResponse

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]

PartialReplace

UpdateResponse PartialReplace(ctx, table, id).ReplaceDocumentRequest(replaceDocumentRequest).Execute()

Partially replaces a document in a table

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/manticoresoftware/manticoresearch-go"
)

func main() {
	table := "table_example" // string | Name of the percolate table
	id := uint64(56) // uint64 | Id of the document to replace
	replaceDocumentRequest := *openapiclient.NewReplaceDocumentRequest(map[string]interface{}(123)) // ReplaceDocumentRequest | 

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

Path Parameters

NameTypeDescriptionNotes
ctxcontext.Contextcontext for authentication, logging, cancellation, deadlines, tracing, etc.
tablestringName of the percolate table
iduint64Id of the document to replace

Other Parameters

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

NameTypeDescriptionNotes

replaceDocumentRequest | ReplaceDocumentRequest | |

Return type

UpdateResponse

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]

Replace

SuccessResponse Replace(ctx).InsertDocumentRequest(insertDocumentRequest).Execute()

Replace new document in a table

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/manticoresoftware/manticoresearch-go"
)

func main() {
	insertDocumentRequest := *openapiclient.NewInsertDocumentRequest("Table_example", map[string]interface{}(123)) // InsertDocumentRequest | 

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

Path Parameters

Other Parameters

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

NameTypeDescriptionNotes
insertDocumentRequestInsertDocumentRequest

Return type

SuccessResponse

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]

Update

UpdateResponse Update(ctx).UpdateDocumentRequest(updateDocumentRequest).Execute()

Update a document in a table

Example

package main

import (
	"context"
	"fmt"
	"os"
	openapiclient "github.com/manticoresoftware/manticoresearch-go"
)

func main() {
	updateDocumentRequest := *openapiclient.NewUpdateDocumentRequest("Table_example", map[string]interface{}({gid=10})) // UpdateDocumentRequest | 

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

Path Parameters

Other Parameters

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

NameTypeDescriptionNotes
updateDocumentRequestUpdateDocumentRequest

Return type

UpdateResponse

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]