@digitalocean/dots - v1.0.1
    Preparing search index...

    Interface Knowledge_basesRequestBuilder

    Builds and executes requests for operations under /v2/gen-ai/knowledge_bases

    interface Knowledge_basesRequestBuilder {
        byKnowledge_base_uuId(
            knowledge_base_uuId: string,
        ): Knowledge_base_uuItemRequestBuilder;
        get(
            requestConfiguration?: RequestConfiguration<
                Knowledge_basesRequestBuilderGetQueryParameters,
            >,
        ): Promise<undefined | ApiListKnowledgeBasesOutput>;
        post(
            body: ApiCreateKnowledgeBaseInputPublic,
            requestConfiguration?: RequestConfiguration<object>,
        ): Promise<undefined | ApiCreateKnowledgeBaseOutput>;
        toGetRequestInformation(
            requestConfiguration?: RequestConfiguration<
                Knowledge_basesRequestBuilderGetQueryParameters,
            >,
        ): RequestInformation;
        toPostRequestInformation(
            body: ApiCreateKnowledgeBaseInputPublic,
            requestConfiguration?: RequestConfiguration<object>,
        ): RequestInformation;
        withUrl(rawUrl: string): Knowledge_basesRequestBuilder;
    }

    Hierarchy

    Index

    Methods

    • To list all knowledge bases, send a GET request to /v2/gen-ai/knowledge_bases.

      Parameters

      Returns Promise<undefined | ApiListKnowledgeBasesOutput>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    post

    • post(
          body: ApiCreateKnowledgeBaseInputPublic,
          requestConfiguration?: RequestConfiguration<object>,
      ): Promise<undefined | ApiCreateKnowledgeBaseOutput>

      To create a knowledge base, send a POST request to /v2/gen-ai/knowledge_bases.

      Parameters

      • body: ApiCreateKnowledgeBaseInputPublic

        Data to create a new knowledge base.

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns Promise<undefined | ApiCreateKnowledgeBaseOutput>

      error when the service returns a 401 status code

      error when the service returns a 404 status code

      error when the service returns a 429 status code

      error when the service returns a 500 status code

      error when the service returns a 4XX or 5XX status code

    • To create a knowledge base, send a POST request to /v2/gen-ai/knowledge_bases.

      Parameters

      • body: ApiCreateKnowledgeBaseInputPublic

        Data to create a new knowledge base.

      • OptionalrequestConfiguration: RequestConfiguration<object>

        Configuration for the request such as headers, query parameters, and middleware options.

      Returns RequestInformation