Skip to content

Commit

Permalink
Merge #441
Browse files Browse the repository at this point in the history
441: Update getting_started code-samples r=alallema a=meili-bot

_This PR is auto-generated._
Update the code-samples.meilisearch.yml according to the [documentation issue](meilisearch/documentation#2499). 
The `api_key` field is missing in the instantiation of the client in the getting started samples.
Add `aSampleMasterKey` as the `api_key`.
cURL example:
```bash
    curl \
  -X POST 'http://localhost:7700/indexes/movies/documents?primaryKey=id' \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer aSampleMasterKey' \
  --data-binary `@movies.json`
````


Co-authored-by: meili-bot <74670311+meili-bot@users.noreply.github.com>
Co-authored-by: Amélie <alallema@users.noreply.github.com>
Co-authored-by: alallema <amelie@meilisearch.com>
  • Loading branch information
4 people authored Jul 11, 2023
2 parents 6aed2ca + 375bf33 commit 2ec7a0f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .code-samples.meilisearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,10 @@ get_one_document_1: |-
get_documents_1: |-
await client.Index("movies").GetDocumentsAsync<Movie>(new DocumentsQuery() { Limit = 2, Filter = "genres = action" });
get_documents_post_1: |-
await client.Index("movies").GetDocumentsAsync<Movie>(new DocumentsQuery() {
Limit = 3,
Fields = new List<string> { "title", "genres", "rating", "language"},
Filter = "(rating > 3 AND (genres=Adventure OR genres=Fiction)) AND language=English"
await client.Index("movies").GetDocumentsAsync<Movie>(new DocumentsQuery() {
Limit = 3,
Fields = new List<string> { "title", "genres", "rating", "language"},
Filter = "(rating > 3 AND (genres=Adventure OR genres=Fiction)) AND language=English"
});
add_or_replace_documents_1: |-
var movie = new[]
Expand Down Expand Up @@ -362,7 +362,7 @@ getting_started_add_documents_md: |-
{
static async Task Main(string[] args)
{
MeilisearchClient client = new MeilisearchClient("http://localhost:7700", "masterKey");
MeilisearchClient client = new MeilisearchClient("http://localhost:7700", "aSampleMasterKey");
var options = new JsonSerializerOptions
{
PropertyNameCaseInsensitive = true
Expand Down

0 comments on commit 2ec7a0f

Please sign in to comment.