From aaad5096a7af4f3cf49911784896d512edc3c453 Mon Sep 17 00:00:00 2001 From: Peter Evans Date: Mon, 11 Nov 2019 23:35:49 +0900 Subject: [PATCH] Update README --- README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/README.md b/README.md index be0297a..6dbd722 100644 --- a/README.md +++ b/README.md @@ -51,6 +51,28 @@ jobs: - run: echo ${{ github.event.client_payload.sha }} ``` +## Client payload + +The GitHub API allows a maximum of 10 top-level properties in the `client-payload` JSON. +If you use more than that you will see an error message like the following. + +``` +No more than 10 properties are allowed; 14 were supplied. +``` + +For example, this payload will fail because it has more than 10 top-level properties. + +```yml +client-payload: ${{ toJson(github) }} +``` + +To solve this you can simply wrap the payload in a single top-level property. +The following payload will succeed. + +```yml +client-payload: '{"github": ${{ toJson(github) }}}' +``` + ## License [MIT](LICENSE)