Invalid Secret Value

help me

i are request send add secret by my project in drone.io 1.0
i use postman, and enviroments global token, repo, url in postman
Response json Invalid Secret Value

image

the payload changed for 1.0. Unfortunately I have not had time to update the API docs yet, however, you can look at the drone-go repository to explore the data structure types, payloads, and json attribute names.

send me, link please

hi,
i needed only one example for json content.
or for example the curl request compatible

{
“name”: “info”,
“value”: “value xxx”,
“event”: [
“push”,
“pull_request”
]
}

please help me,
i have multiples proyect by add secrets via postman or curl (scritp.sh)

The source code for the specific endpoint inputs can be found here.

A simple curl command to create a new secret named test with a value of foo would be:

curl --request POST \
  --url https://<drone url>/api/repos/<repo>/secrets \
  --header 'authorization: Bearer <drone token>' \
  --header 'content-type: application/json' \
  --data '{
	"name": "test",
	"data": "foo",
	"pull_request": true
}'

hi
thank you
via postman i change json atribute “value” by “data” and response 200

one quention:
it is ok use event in json body?
{
“name”: “info”,
“data”: “value xxx”,
“event”: [
“push”,
“pull_request”
]
}

or replace by next:

{
“name”: “info”,
“data”: “value xxx”,
“pull_request”: true
}