/* SPDX-License-Identifier: Apache-2.0 * * The OpenSearch Contributors require contributions made to * this file be licensed under the Apache-2.0 license or a * compatible open source license. */ /* * Modifications Copyright OpenSearch Contributors. See * GitHub history for details. * * Licensed to Elasticsearch B.V. under one or more contributor * license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright * ownership. Elasticsearch B.V. licenses this file to you under * the Apache License, Version 2.0 (the "License"); you may * not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ // ███╗ ██╗ ██████╗ ████████╗██╗ ██████╗███████╗ // ████╗ ██║██╔═══██╗╚══██╔══╝██║██╔════╝██╔════╝ // ██╔██╗ ██║██║ ██║ ██║ ██║██║ █████╗ // ██║╚██╗██║██║ ██║ ██║ ██║██║ ██╔══╝ // ██║ ╚████║╚██████╔╝ ██║ ██║╚██████╗███████╗ // ╚═╝ ╚═══╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝╚══════╝ // ----------------------------------------------- // // This file is automatically generated // Please do not edit these files manually // Run the following in the root of the repos: // // *NIX : ./build.sh codegen // Windows : build.bat codegen // // ----------------------------------------------- // ReSharper disable RedundantUsingDirective using System; using System.Collections.Generic; using System.Collections.Specialized; using System.Linq; using System.Text; using System.Threading; using System.Threading.Tasks; using OpenSearch.Net; using static OpenSearch.Net.HttpMethod; // ReSharper disable InterpolatedStringExpressionIsNotIFormattable // ReSharper disable once CheckNamespace // ReSharper disable InterpolatedStringExpressionIsNotIFormattable // ReSharper disable RedundantExtendsListEntry namespace OpenSearch.Net.Specification.IngestApi { /// /// Ingest APIs. /// Not intended to be instantiated directly. Use the property /// on . /// /// public partial class LowLevelIngestNamespace : NamespacedClientProxy { internal LowLevelIngestNamespace(OpenSearchLowLevelClient client): base(client) { } ///DELETE on /_ingest/pipeline/{id} ///Pipeline ID ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse DeletePipeline(string id, DeletePipelineRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(DELETE, Url($"_ingest/pipeline/{id:id}"), null, RequestParams(requestParameters)); ///DELETE on /_ingest/pipeline/{id} ///Pipeline ID ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.delete_pipeline", "id")] public Task DeletePipelineAsync(string id, DeletePipelineRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(DELETE, Url($"_ingest/pipeline/{id:id}"), ctx, null, RequestParams(requestParameters)); ///GET on /_ingest/pipeline ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse GetPipeline(GetPipelineRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(GET, "_ingest/pipeline", null, RequestParams(requestParameters)); ///GET on /_ingest/pipeline ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.get_pipeline", "")] public Task GetPipelineAsync(GetPipelineRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(GET, "_ingest/pipeline", ctx, null, RequestParams(requestParameters)); ///GET on /_ingest/pipeline/{id} ///Comma separated list of pipeline ids. Wildcards supported ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse GetPipeline(string id, GetPipelineRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(GET, Url($"_ingest/pipeline/{id:id}"), null, RequestParams(requestParameters)); ///GET on /_ingest/pipeline/{id} ///Comma separated list of pipeline ids. Wildcards supported ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.get_pipeline", "id")] public Task GetPipelineAsync(string id, GetPipelineRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(GET, Url($"_ingest/pipeline/{id:id}"), ctx, null, RequestParams(requestParameters)); ///GET on /_ingest/processor/grok ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse GrokProcessorPatterns(GrokProcessorPatternsRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(GET, "_ingest/processor/grok", null, RequestParams(requestParameters)); ///GET on /_ingest/processor/grok ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.processor_grok", "")] public Task GrokProcessorPatternsAsync(GrokProcessorPatternsRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(GET, "_ingest/processor/grok", ctx, null, RequestParams(requestParameters)); ///PUT on /_ingest/pipeline/{id} ///Pipeline ID ///The ingest definition ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse PutPipeline(string id, PostData body, PutPipelineRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(PUT, Url($"_ingest/pipeline/{id:id}"), body, RequestParams(requestParameters)); ///PUT on /_ingest/pipeline/{id} ///Pipeline ID ///The ingest definition ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.put_pipeline", "id, body")] public Task PutPipelineAsync(string id, PostData body, PutPipelineRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(PUT, Url($"_ingest/pipeline/{id:id}"), ctx, body, RequestParams(requestParameters)); ///POST on /_ingest/pipeline/_simulate ///The simulate definition ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse SimulatePipeline(PostData body, SimulatePipelineRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(POST, "_ingest/pipeline/_simulate", body, RequestParams(requestParameters)); ///POST on /_ingest/pipeline/_simulate ///The simulate definition ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.simulate", "body")] public Task SimulatePipelineAsync(PostData body, SimulatePipelineRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(POST, "_ingest/pipeline/_simulate", ctx, body, RequestParams(requestParameters)); ///POST on /_ingest/pipeline/{id}/_simulate ///Pipeline ID ///The simulate definition ///Request specific configuration such as querystring parameters & request specific connection settings. public TResponse SimulatePipeline(string id, PostData body, SimulatePipelineRequestParameters requestParameters = null) where TResponse : class, IOpenSearchResponse, new() => DoRequest(POST, Url($"_ingest/pipeline/{id:id}/_simulate"), body, RequestParams(requestParameters)); ///POST on /_ingest/pipeline/{id}/_simulate ///Pipeline ID ///The simulate definition ///Request specific configuration such as querystring parameters & request specific connection settings. [MapsApi("ingest.simulate", "id, body")] public Task SimulatePipelineAsync(string id, PostData body, SimulatePipelineRequestParameters requestParameters = null, CancellationToken ctx = default) where TResponse : class, IOpenSearchResponse, new() => DoRequestAsync(POST, Url($"_ingest/pipeline/{id:id}/_simulate"), ctx, body, RequestParams(requestParameters)); } }