Fix search publication mechanism.

This commit is contained in:
Florian THIERRY
2024-03-15 17:39:04 +01:00
parent 6e2b86153e
commit da1937cb31
18 changed files with 258 additions and 7 deletions

View File

@@ -0,0 +1,25 @@
meta {
name: Create a new publication
type: http
seq: 1
}
post {
url: {{url}}/api/publications
body: json
auth: bearer
}
auth:bearer {
token: {{bearerToken}}
}
body:json {
{
"title" : "Test",
"text" : "Test",
"description" : "Test",
"illustrationId" : "e2a5618e-ef83-4e83-b8ec-0aa129173f85",
"categoryId" : "3f4b4540-a901-92f3-1c15-8ec9172f820e"
}
}

View File

@@ -0,0 +1,15 @@
meta {
name: Delete an existing publication
type: http
seq: 3
}
delete {
url: {{url}}/api/publications/{{publicationId}}
body: none
auth: bearer
}
auth:bearer {
token: {{bearerToken}}
}

View File

@@ -0,0 +1,15 @@
meta {
name: Get a publication by its id
type: http
seq: 4
}
get {
url: {{url}}/api/publications/{{publicationId}}
body: none
auth: bearer
}
auth:bearer {
token: {{bearerToken}}
}

View File

@@ -0,0 +1,19 @@
meta {
name: Search publications
type: http
seq: 5
}
get {
url: {{url}}/api/publications?query=test
body: none
auth: bearer
}
query {
query: test
}
auth:bearer {
token: {{bearerToken}}
}

View File

@@ -0,0 +1,25 @@
meta {
name: Update an existing publication
type: http
seq: 2
}
put {
url: {{url}}/api/publications/{{publicationId}}
body: json
auth: bearer
}
auth:bearer {
token: {{bearerToken}}
}
body:json {
{
"title" : "Le titre de la publication.",
"text" : "Un autre contenu de la publication.",
"description" : "Une autre description de la publication",
"image" : "https://google.com/logos/doodles/2024/celebrating-the-flat-white-6753651837110463-s.png",
"categoryId" : "fd424c2f-6e58-4812-a179-00e50a0eab05"
}
}