GitHub action to update a Notion page property on commit created by merging a Pull Request.
Originally built for updating version tag in Notion page on commit. See the test workflow as an example.
uses: szenius/[email protected]
with:
gh-username: "username"
gh-token: ${{ secrets.GH_ACCESS_TOKEN }}
notion-key: ${{ secrets.NOTION_KEY }}
notion-property-name: "Status"
notion-update-value: "Merged"
notion-property-type: "rich_text"
existing-value: "overwrite"
gh-username
: GitHub username of user who has access to the repositorygh-token
: GitHub access token of user who has access to the repositorynotion-key
: Notion Integration Secret Keynotion-property-name
: Notion Page property to be updatednotion-update-value
: New value for Notion page propertynotion-property-type
(optional): Type of Notion Page property. Can berich_text
ormulti_select
. Defaults torich_text
.existing-value
(optional): What to do with existing value in field to be updated. Can beappend
oroverwrite
. Defaults tooverwrite
ifnotion-property-type
isrich_text
append
ifnotion-property-type
ismulti_select
The test workflow is linked to this Notion database.