How can I fill in short description when creating a new repo?

I’d like to fill in the short description or long description of a new repo under my account. How can I do that with the API?

Assuming you are using the Docker Trusted Registry, you use the shortDecription and longDescription labels in the json body of the post. Something like this:

    "name": "new-repo",
    "shortDescription": "Short Description",
     "longDescription": "Longer description also known as the README.",
      "visibility": "public",
      "scanOnPush": false

or using curl something like this:

curl -X POST --header "Content-Type: application/json" --header "Accept: application/json" --header "X-Csrf-Token:<removed>" -d "{\"name\": \"new-repo\",\"shortDescription\": \"Short Description\",\"longDescription\": \"Longer description also known as the README.\",\"visibility\": \"public\",\"scanOnPush\": false}" "https://<your dtr dns>/api/v0/repositories/<target namespace>"