meilisearch / meilisearch-dotnet Goto Github PK
View Code? Open in Web Editor NEW.NET wrapper for the Meilisearch API
Home Page: https://meilisearch.com
License: MIT License
.NET wrapper for the Meilisearch API
Home Page: https://meilisearch.com
License: MIT License
Fill "Release" section in Development workflow
Make the package easy to use. The getting started should be:
Meilisearch ms = new Meilisearch("http://localhost:7700", "masterKey");
Index index = await ms.createIndex("books")
var updateStatus = await index.AddorUpdateDocuments(new[]{new Movie {Id = "1", Name = "Batman"}});
π
Currently, the only way to delete an index is from an Index
instance like:
index.Delete();
We should be able to delete an Index
from the client instance:
client.DeleteIndex("indexUID");
The MeiliSearch documentation specify that the SearchQuery.Filters property is of type string and not array of string : https://docs.meilisearch.com/guides/advanced_guides/search_parameters.html#filters
The associated type of this property should be changed and test updated to cover this. Without this change, it's impossible to use this field (at least with the version 0.17.0 that i have on my laptop).
Note : I'll take time to do a PR in order to fix that.
Currently, the get_all_indexes
method returns a raw list of object, but not a list of Index
instance. This is the only index-related method that does not return an Index
instance.
An instance is more convenient to manipulate than a raw object. See this example.
TODO
get_all_indexes
: make it return a list of Index
instancesget_all_raw_indexes
: a method that returns the list of object of indexes, so the response of the MeiliSearch server.get_all_raw_indexes
in get_all_indexes
.
Related to meilisearch/integration-guides#122
get_all_indexes
might be named differently in this package. Keep the already existing way of naming in this package to stay idomatic with the language and the repository.
Sorry if this is already partially/completely implemented, feel free to let me know about the state of this issue.
We are using the search option with the Offset & Limit properties for the use of pagination using the below code snippet.
var searchQuery = new SearchQuery
{
AttributesToHighlight = new string[] { "title", "description", "updates" },
AttributesToCrop = new string[] { "description", "updates" },
CropLength = 90,
Offset = startIndex,
Limit = pageSize,
Filters = string.IsNullOrWhiteSpace(filterQuery) ? null : filterQuery,
};
var searchResponse = await index.Search<FormattedSearchResult>(keyword, searchQuery).ConfigureAwait(false);
TotalCount = searchResponse.NbHits;
Based on the change in the Offset & Limit values i.e., startIndex and pageSize the response value for the number of matches property βNbHitsβ keeps changing for the same searchQuery parameters as mentioned above. Find the result screenshot we had based on this.
Offset β 0 & Limit β 10.
Offset β 10 & Limit β 10.
As it can be seen above from the screenshots values of the NbHits property varies while increasing the Offset value for the same query & search parameters. This makes the pagination improper for the same search keyword and search parameters. We are using Meilisearch version 0.20.0. And meilisearch dotnet version is 0.4.2
Is this an existing bug.? Or Any work around available for this issue.?
With:
public class Movie
{
public int Id { get; set; }
public string Name { get; set; }
}
MeilisearchClient client = new MeilisearchClient("http://localhost:7700", "masterKey");
var index = client.CreateIndex("movies");
var documents = new Movie[] {
new Movie {Id = 1, Name = "Batman"}
};
var updateStatus = await index.AddDocuments<Movie>(documents);
Movie movie = await index.GetDocument<Movie>(1);
I got the error "impossible to convert int into a string".
The GetDocument
method should be able to accept an int or a string since MeiliSearch can accept a string or an int as a document identifier.
TODO:
In the below implementation we're trying to create index with given name, if we get an exception that matches specific exception message we try getting index. Instead of that wouldn't it be good to first try getting index if the result is null then trying to create a new index? In that case we'll also decrease call/request counts in case of index is already exists.
meilisearch-dotnet/src/Meilisearch/MeilisearchClient.cs
Lines 114 to 131 in 72c548c
My suggested implementation:
private async Task<Index> GetOrCreateIndex(string uid)
{
var index = await _client.GetIndex(uid);
if (index == null)
{
index = await _client.CreateIndex(uid);
}
return index;
}
We are trying to create new index or delete existing from the client using the below code.
Create index using below methods
MeilisearchClient client = new MeilisearchClient(ConfigurationManager.AppSettings["SearchURL"],ConfigurationManager.AppSettings["SearchKey"]);
var newIndex = await client.CreateIndex("testing");
var Index = await client.GetOrCreateIndex("testing").ConfigureAwait(false);
While calling the above methods to create the index, the hosted URL(SearchURL) goes down result in the timeout. We then have to start/stop the meilisearch server to enable the hosted URL to access the search. We are using the nuget Meilisearch Dotnet version - 0.4.2.(Meilisearch version 0.20.0) Meilisearch server in which we have hosted the SearchURL is in OS:Debian we have Same problem arises while deleting any of the existing index as well.
Anyone have an idea regarding this.?
Add a test to check the filter
parameter can work with values containing spaces
Example:
"filter": "genre = 'sci fi'"
Related to meilisearch/integration-guides#30
Let's be allies and make this change that means a lot.
Here is a blog post that explain a little more why it's important, and how to easily do it. It will be a bit more complicated with automation, but we still should do it!
Also, if you are a maintainer, feel free to add any clarification and instruction about this issue.
Sorry if this is already partially/completely implemented, feel free to let me know about the state of this issue in the repo.
Related to meilisearch/integration-guides#120
This SDK provides a method to get an index (getIndex
) and this method returns an instance of Index
. Some users want to get the raw version of the index, I mean the exact JSON response returned by the MeiliSearch server, not an instance.
Some SDKs already provide a way to get this raw index information but this is not convenient, example in PHP:
$client->index('movies')->fetchRawInfo();
We need to add the getRawIndex
method, accessible from the Client
instance, to make it more convient.
Prototype:
getRawIndex(string indexUID) -> object/struct/dict of the MeiliSearch response
Ex in PHP:
$client->getRawIndex('movies');
TODO:
getRawIndex()
method to the Client
instance without duplicating the code (if fetchRawInfo()
already exists for example)We should erase the indexes present in the MeiliSearch instance before starting the tests: this is dangerous because we run the test in a context we don't know.
This issue is not a problem on the CI, but is not really convenient when running tests locally.
MeilisearchClient client = new MeilisearchClient("http://xxxxxx:7700", "masterKey");
var index = await client.GetAllIndexes();
var ceshi = await client.CreateIndex("movies1", "Id")
Error when getting all indexes:
System.MissingMethodException:βMethod not found: 'System.IO.Stream System.Text.Encoding.CreateTranscodingStream(System.IO.Stream, System.Text.Encoding, System.Text.Encoding, Boolean)'.β
The data can be returned normally by using the post man test request interface:
It may be a problem with the return value
As MeiliSearch grows so does its SDK's. More and more SDK's rises from the ground and they all deserve to be as well documented as the core engine itself.
The most common way for a user to understand MeiliSearch is to go to its official documentation. As of yesterday all examples in the documentation were made with cURL
. Unfortunately, most of our users do not communicate with MeiliSearch directly with cURL
. Which forces them to search for the specific references somewhere else (in the readme's, in the sdk's code itself,..). This makes for unnecessary friction.
We want our documentation to include all SDK's
As a first step we want all examples to be made using the most possible SDK's. As did Stripe and Algolia.
examples with curl, javascript and soon enough this SDK too!
To achieve this it is expected from this SDK to create a sample file containing all the code samples needed by the documentation.
These are the steps to follow:
The sample file is a yaml file added at the root of each MeiliSearch SDK.
Sample files are created based on the sample-template.yaml
file.
sample-template
file:
get_one_index_1: |-
list_all_indexes_1: |-
create_an_index_1: |-
...
This template is accessible publicly here or in the public directory : .vuepress/public/sample-template.yaml
of the documentation.
The name of the file should be .code-samples.meilisearch.yaml
After creating the sample file with the content of the sample template you should have a file containing all the sampleId
's.
get_one_index_1: |-
list_all_indexes_1: |-
create_an_index_1: |-
...
By the name of the different sampleId
you should know where that code sample will be added to the documentation.
For example, create_an_index_1
is the first example in the API References of the index creation.
Using the already existing cURL
example in the documentation you should see what is expected from that sample. It is very important that you look at the already existing samples in the documentation as it gives you the parameters to use in your sample to match with the rest of the documentation.
Good sample based on documentation:
create_an_index_1: |-
client.createIndex({ uid: 'movies' })
Bad sample that does not match with the response.
create_an_index_1: |-
client.createIndex({ uid: 'otherName' })
Each sample is expected to be written in the respective SDK language.
Javascript example:
get_one_index_1: |-
client.getIndex('movies').show()
list_all_indexes_1: |-
client.listIndexes()
create_an_index_1: |-
client.createIndex({ uid: 'movies' })
...
The complete cURL
sample file is available at the root of the documentation repository.
Every other SDK sample file should be available at the root of their respective repository.
There is one exception to the formatting rule.
When the sampleId
finishes with _md
it means it is expected to be written in markdown format.
JavaScript sample id with _md extension:
Once your sample file is filled with the code samples, you will need to create a pull request on the documentation repository.
Open the following file in your IDE:
.vuepress/code-samples/sdks.json
And add your sample file to the list:
[
...
{
"language": "sdk-language",
"label": "sdk-label",
"url": "url to yaml file"
}
]
The language
key expect a supported language for the code highlight.
The label
key is the name of the tab. While label
and language
could have been the same, it created some conflict (i.e: bash
and cURL
).
The url
is the raw link to access your sample file. It should look like this:
https://raw.githubusercontent.com/[PROJECT]/[REPO]/.code-samples.meilisearch.yaml
According to meilisearch/integration-guides#37, and after this decision, search method should always use the POST
search route. The GET
search route will be considered deprecated in this SDK.
TODO:
UpdateIndex()
method in the Index
class. This method should be renamed as Update()
.UpdateIndex()
in the Client
class, calling the Update()
newly created in Index
.Trying to delete an index that does not exist on the MeiliSearch server will throw an error. To delete it without any error no matter what if it exists or not, we need a new method.
delete_index_if_exists
: it deletes the index but does not throw any error if the index does not exist.Example: https://github.com/meilisearch/meilisearch-python/pull/268/files
delete_index_if_exists
might be named differently in this package. Keep the already existing way of naming in this package to stay idomatic with the language and the repository.
Related to meilisearch/integration-guides#107
Sorry if this is already partially/completely implemented, feel free to let me know about the state of this issue.
SearchResult is missing NbHits & ExhaustiveNbHits fields. These are returned by the api but not mapped to the response object.
We have created an index in our meilisearch server and pushed bulk data from our database into the index. We are using the meilisearch version - 0.20.0 The current number of documents we have retried from the below code is 76,252.
var stats = await client.Index(index).GetStats();
Console.WriteLine(stats.NumberOfDocuments);
After that we pushed two batches of data each containing 96 & 4 documents each. So totally 100 documents pushed to the index. But when we checked the documents using the above code. Count has increased to 76,259. Remaining 93 counts are not retrieved from the stats of the index.
We have also checked the status of the update ID's of the above two batches(96 & 4) using the below code and it is marked as "Processed".
var updateStatus = await client.Index(index).GetUpdateStatus(updateId);
Console.WriteLine(updateStatus.Status);
Is there any delay in moving the processed updated Id documents into the "GetStats()" method "NumberOfDocuments" property as we are facing a discrepancy of 93 records.? Please provide any insight on this.
I'll create a GitHub action for next years.
As described in this section I have to specify facetFilters
parameter to narrow search result. But I think this feature is not available.
Hello!
I was having a peek at the dependencies of this project, and I encountered the Microsoft.AspNetCore.WebUtilities
dependency. This dependency has itself 2 dependencies on other projects..
What is the reason for this package? As far as I can see, it is only used to generate some query strings:
meilisearch-dotnet/src/Meilisearch/Index.cs
Line 129 in 8d5b14c
I believe these do not belong in this library for several reasons:
AspNetCore
package dependency??query=strings&and=stuff
? :) This can easily be done with normal C#.Removing this dependency will increase the surface area that cna be reached with this library because it needs fewer dependencies to function and could increase adoption by removing a "wonky" dependency :)
Create a GHA triggered on each tag to publish the package to nuget.org.
Randomly, the CI makes the tests fails
see: https://github.com/meilisearch/meilisearch-dotnet/runs/3896895492
β Meilisearch.Tests.IndexTests.UpdatePrimaryKey [18ms]
[xUnit.net 00:00:03.15] Meilisearch.Tests.MeilisearchClientTests.GetDumpStatusById [FAIL]
[xUnit.net 00:00:03.15] Expected dumpStatus.Status to be "done" with a length of 4, but "in_progress" has a length of 11, differs near "in_" (index 0).
[xUnit.net 00:00:03.15] Stack Trace:
[xUnit.net 00:00:03.15] at FluentAssertions.Execution.XUnit2TestFramework.Throw(String message)
[xUnit.net 00:00:03.15] at FluentAssertions.Execution.TestFrameworkProvider.Throw(String message)
[xUnit.net 00:00:03.16] at FluentAssertions.Execution.DefaultAssertionStrategy.HandleFailure(String message)
[xUnit.net 00:00:03.16] at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc)
[xUnit.net 00:00:03.16] at FluentAssertions.Execution.AssertionScope.FailWith(Func`1 failReasonFunc)
[xUnit.net 00:00:03.16] at FluentAssertions.Primitives.StringEqualityValidator.ValidateAgainstLengthDifferences()
[xUnit.net 00:00:03.16] at FluentAssertions.Primitives.StringValidator.Validate()
[xUnit.net 00:00:03.16] at FluentAssertions.Primitives.StringAssertions`1.Be(String expected, String because, Object[] becauseArgs)
[xUnit.net 00:00:03.16] /home/runner/work/meilisearch-dotnet/meilisearch-dotnet/tests/Meilisearch.Tests/MeilisearchClientTests.cs(87,0): at Meilisearch.Tests.MeilisearchClientTests.GetDumpStatusById()
[xUnit.net 00:00:03.16] --- End of stack trace from previous location where exception was thrown ---
The dump creation is not finished and that's why the dump fails.
We should find a way to avoid this random failure.
As the library manipulates JSON data, Its the best practices to use it as a stream rather than holding the entire memory for the same. More details can be found here.
https://www.stevejgordon.co.uk/sending-and-receiving-json-using-httpclient-with-system-net-http-json
We need methods to add and update the documents of MeiliSearch in batch instead of letting the users call addDocuments
in a loop.
addDocumentsInBatches
addDocumentsInBatches(documents, batchSize = 1000, primaryKey = nil)
batchSize
and primaryKey
are optional parameters
updateDocumentsInBatches
updateDocumentsInBatches(documents, batchSize = 1000, primaryKey = nil)
batchSize
and primaryKey
are optional parameters
Example: meilisearch/meilisearch-python#260
addDocumentsInBatches
andd updateDocumentsInBatches
might be named differently in this package. Keep the already existing way of naming in this package to stay idiomatic with the language and the repository.
Also, if you are a maintainer, feel free to add any clarification and instruction about this issue related to the specific languages of the repo.
Related to meilisearch/integration-guides#106
Sorry if this is already partially/completely implemented, feel free to let me know about the state of this issue in the repo.
add_documents_json
instead of addDocumentsJson
). Keep the already existing way of naming in this package to stay idiomatic with the language and this repository.
π£ We strongly recommend doing multiple PRs to solve all the points of this issue
MeiliSearch v0.23.0 introduces two changes:
Content-type
header for every route requiring a payload (POST
and PUT
routes)Here are the expected changes to completely close the issue:
Currently, the SDKs always send Content-Type: application/json
to every request. Only the POST
and PUT
requests should send the Content-Type: application/json
and not the DELETE
and GET
ones.
Add the following methods and π₯ the associated tests π₯ to ADD the documents. Depending on the format type (csv
or ndjson
) the SDK should send Content-Type: application/x-dnjson
or Content-Type: text/csv
)
addDocumentsJson(string docs, string primaryKey)
addDocumentsCsv(string docs, string primaryKey)
addDocumentsCsvInBatches(string docs, int batchSize, string primaryKey)
addDocumentsNdjson(string docs, string primaryKey)
addDocumentsNdjsonInBatches(string docs, int batchSize, string primaryKey)
Add the following methods and π₯ the associated tests π₯ to UPDATE the documents. Depending on the format type (csv
or ndjson
) the SDK should send Content-Type: application/x-dnjson
or Content-Type: text/csv
)
updateDocumentsJson(string docs, string primaryKey)
updateDocumentsCsv(string docs, string primaryKey)
updateDocumentsCsvInBatches(string docs, int batchSize, string primaryKey)
updateDocumentsNdjson(string docs, string primaryKey)
updateDocumentsNdjsonInBatches(string docs, int batchSize, string primaryKey)
docs
are the documents sent as String
primaryKey
is the primary key of the index
batchSize
is the size of the batch. Example: you can send 2000 documents in raw String in docs
and ask for a batchSize
of 1000, so your documents will be sent to MeiliSearch in two batches.
Example of PRs:
Related to: meilisearch/integration-guides#146
If this issue is partially/completely implemented, feel free to let us know.
EDIT:
The files needed for the tests when creating the csv and ndjson methods are available here:
Create GetKeys
according to this route: https://docs.meilisearch.com/reference/api/keys.html#get-keys
Some routes present in MeiliSearch are not implemented in this package yet:
The settings routes and sub-routes are the most urgent ones π
This issue is to improve the tests relative to the Search
method. It means improving this file by adding tests:
Filters
tests with AND
and OR
(see the end of this page of docs)This file might need changes to fit those new tests.
We should add a basic error handler, with these 2 custom errors:
MeiliSearchApiError
MeiliSearchCommunicationError
If I'm not wrong, @barbados-clemens you created one in your previous meilisearch-dotnet repo (not available anymore) π
Was this complicated to add?
FYI: Even if it's not documented yet, MeiliSearch API has a great error handler, and returns this kind of JSON when an error is found:
It could be great to let the user access message
, errorCode
, errorType
and errorLink
.
Hi,
Can you add code to get/set Searchable attributes
I suggest the following to go into Index.cs
`
///
/// <summary>
/// Get searchable attributes.
/// </summary>
/// <returns>An Ienumerable of strings that contains searchable attributes sorted by order of importance (arranged from the most important attribute to the least important attribute).</returns>
public async Task<IEnumerable<string>> GetSearchableAttributes()
{
return await this.client.GetFromJsonAsync<List<string>>($"/indexes/{this.Uid}/settings/searchable-attributes");
}
`
As stated in meilisearch/meilisearch#810 and meilisearch/integration-guides#36 the sys-info routes will be considered as deprecated in MeiliSearch v0.13.0. These routes should be removed from this SDK accordingly.
Following #54
Related to: meilisearch/integration-guides#136
In the README, we want to add the Custom Search With Filters
sub section in the Getting Started
section to make the users are aware of filtering.
This should
Custom Search
sub section---------- beginning of the content
If you want to enable filtering, you must add your attributes to the filterableAttributes
index setting.
--- Add an example corresponding to the current repository. See this example in JS:
await index.updateAttributesForFaceting([
'id',
'genres'
])
--- end of example
You only need to perform this operation once.
Note that MeiliSearch will rebuild your index whenever you update filterableAttributes
. Depending on the size of your dataset, this might take time. You can track the process using the update status.
Then, you can perform the search:
--- Add an example corresponding to the current repository. See this example in JS:
await index.search(
'wonder',
{
filter: ['id > 1 AND genres = Action']
}
)
--- end of example
{
"hits": [
{
"id": 2,
"title": "Wonder Woman",
"genres": ["Action","Adventure"]
}
],
"offset": 0,
"limit": 20,
"nbHits": 1,
"processingTimeMs": 0,
"query": "wonder"
}
------------- end of the content
π£ Example of PR: https://github.com/meilisearch/meilisearch-js/pull/1059/files
Please read:
https://github.com/Microsoft/vs-threading/blob/main/doc/cookbook_vs.md#should-i-await-a-task-with-configureawaitfalse
https://medium.com/bynder-tech/c-why-you-should-use-configureawait-false-in-your-library-code-d7837dce3d7f
Not using ConfigureAwait(false)
in a library that might be used by an app that has a SynchronizationContext could result in a loss of performance and perhaps some issues.
This library should use ConfigureAwait(false)
everywhere to prevent this
Currently when doing this test:
var indexUID = "BasicDocumentsUpdateTest";
Index index = await this.client.GetOrCreateIndex(indexUID);
// Add the documents
UpdateStatus update = await index.AddDocuments(new[]
{
new Movie { Id = "1", Name = "Batman", Genre = "Action" },
new Movie { Id = "2", Name = "Superman" }
});
// Update the documents
update = await index.UpdateDocuments(new[] { new Movie { Id = "1", Name = "Ironman" } });
// Check the documents have been updated and added
var docs = await index.GetDocuments<Movie>();
Assert.Equal("1", docs.First().Id);
Assert.Equal("Ironman", docs.First().Name);
Assert.Equal("Action", docs.First().Genre);
Assert.Equal("2", docs.ElementAt(1).Id);
Assert.Equal("Superman", docs.ElementAt(1).Name);
docs.ElementAt(1).Genre.Should().BeNull();
The Assert.Equal("Action", docs.First().Genre);
line fails because Genre
is null
but it should not be. The add-or-update-documents route should be a partial update, so the value a Genre
should still be "Action"
.
To keep the getting started simple to try, but to also make documentation examples compatible with the getting started, we are replacing book
examples with movies
examples.
The Movie dataset is used throughout the documentation. The only place where book is used is in the tests (which can stay as it is) and in our getting started.
const index = client.index('movies')
Provided dataset should be changed with the following:
const documents = [
{ id: 1, title: 'Carol', genres: ['Romance', 'Drama'] },
{ id: 2, title: 'Wonder Woman', genres: ['Action', 'Adventure'] },
{ id: 3, title: 'Life of Pi', genres: ['Adventure', 'Drama'] },
{ id: 4, title: 'Mad Max: Fury Road', genres: ['Adventure', 'Science Fiction'] },
{ id: 5, title: 'Moana', genres: ['Fantasy', 'Action']},
{ id: 6, title: 'Philadelphia', genres: ['Drama'] },
]
// If the index 'movies' does not exist, MeiliSearch creates it when you first add the documents.
According to the Getting Started, I can write:
MeilisearchClient client = new MeilisearchClient("http://localhost:7700", "masterKey");
var index = client.CreateIndex("movies");
var documents = new Movie[] {
new Movie {Id = "1", Name = "Batman"},
new Movie {Id = "2", Name = "Interstellar"},
new Movie {Id = "3", Name = "Batman Begins"}
};
var updateStatus = await index.AddDocuments<Movie>(documents);
but I cannot write:
MeilisearchClient client = new MeilisearchClient("http://localhost:7700", "masterKey");
var index = client.GetIndex("movies");
var documents = new Movie[] {
new Movie {Id = "1", Name = "Batman"},
new Movie {Id = "2", Name = "Interstellar"},
new Movie {Id = "3", Name = "Batman Begins"}
};
var updateStatus = await index.AddDocuments<Movie>(documents);
Because 'Task<Index>'
does not contain a definition for AddDocuments
.
If the index is already created, I should have the possibility to use GetIndex
instead of CreateIndex
to manipulate my already existing index in the same way π
Both methods should return the same object.
TODO:
According to this discussion
When manipulating indexes (get/create/update), the MeiliSearch server returns the following information related to the index:
uid
: the uid of the indexprimaryKey
: the primary key of the indexupdateAt
: when the index has been updatedcreatedAt
: when the index has been createdThis SDK, when manipulating indexes (get/create/update) returns an instance of Index
which already contains the primaryKey
and uid
members.
It means we can currently get the primaryKey
and the uid
, but not updatedAt
and createdAt
.
TODO:
updatedAt
and createdAt
member in the Index
class/struct (depending on the language).primaryKey
is already updated. Ex: when getting the index with getIndex()
primaryKey
, updatedAt
, and createdAt
might be named differently in this package (ex: primary_key
instead). Keep the already existing way of naming in this package to stay idiomatic with the language and the repository.
Also, if you are a maintainer, feel free to add any clarification and instruction about this issue related to the specific languages of the repo.
Related to meilisearch/integration-guides#121
Sorry if this is already partially/completely implemented, feel free to let me know about the state of this issue in the repo.
Please do it.
Complete:
Installation
partGetting Started
Since v0.15.0, MeiliSearch exposes a new functionality: dumps
This feature should be implemented in this SDK following this specificacions
We should add a linter to this project, at least for the code style.
For example, I can see here the same kind of method but with not the same style (especially in the name of the function):
meilisearch-dotnet/tests/Meilisearch.Tests/DocumentTests.cs
Lines 23 to 43 in 086c738
The goal is to provide a better environment for contribution π
I'm not a .NET dev, so I'm not aware of the lint tools in .NET. What do you suggest?
NB: I'm adding an editorconfig file in this PR #8 but it's just about general style indentation.
In #165 I implemented an HttpRequest
class to implement our own HTTP methods (PostAsJsonAsync
...) to remove the charset-utf8
content type.
However, I'm not a c# dev, and I feel like I missed something: at first I wanted to "extend" the HttpClient
class and override PostAsJsonAsync
, but without any success. So I came to the current implementation you can find in the main
branch.
Does anyone know a better way to implement this?
Feel free to open any PR!
Currently only GetSettings
, UpdateSettings
and ResetSettings
are implemented. These routes manage all the settings by calling this "general" settings route.
But currently in this SDK, no method are implemented to call the sub-routes of each settings.
We need to add the GetXXX
, UpdateXXX
and ResetXXX
where XXX
are the following settings:
No need to do all the settings in the same PRs of course, any contributions, even small, are welcome πβ€οΈ
Feel free to ask any question!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.