Skip to content

Json Payload #42

Answered by kursataktas
ansharfirman asked this question in Q&A
Discussion options

You must be logged in to vote

Hi @ansharfirman

You can do this both with CLI or a Config file.

CLI;
ddosify -t http://localhost:8083/v2/school -p POST -h 'Content-Type:application/json' -b '{"name":"lorem ipsum", "grade": 1,}'

Config File;
ddosify -config config.json

config.json;

{
    "request_count": 1,
    "duration": 1,
    "steps": [{
        "id": 1,
        "headers": {"Content-Type": "application/json"},
        "url": "http://localhost:8083/v2/school",
        "method": "POST",
        "payload_file": "./payload.json"
    }]
}

payload.json;

{
    "name": "lorem ipsum",
    "grade": 1,
}

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by kursataktas
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants