Newer
Older
web-services / base-line / examples.http
@Nicolas Thouvenin Nicolas Thouvenin on 4 Oct 2021 1 KB fix: Bad json in examples
# These examples can be used directly in VSCode, using REST Client extension (humao.rest-client)

# Parse un flux JSON, et le returne sans modification
POST https://base-line.services.inist.fr/v1/echo/json?indent=true HTTP/1.1
Content-Type: application/json

[
	{ "id":"12345","value": "A" },
	{ "id":"6789","value": "B" }
]
###




# Parse un flux CSV, et le retourne sans modification
POST https://base-line.services.inist.fr/v1/echo/csv HTTP/1.1
Content-Type: text/csv

id,value
12345,A
6789,B
###





# Reçoit un flux, et le retourne sans modification et sans analsye
POST https://base-line.services.inist.fr/v1/echo/raw HTTP/1.1
Content-Type: text/plain

OK
###




# Parse un flux JSON, et donne la valeur true au champ value
POST https://base-line.services.inist.fr/v1/true/json?indent=true HTTP/1.1
Content-Type: application/json

[
	{ "id":"12345","value": "A" },
	{ "id":"6789","value": "B" }
]
###




# Parse un flux CSV, et donne la valeur true au champ value
POST https://base-line.services.inist.fr/v1/true/csv HTTP/1.1
Content-Type: text/csv

id,value
12345,A
6789,B
###