Update the PANDIUM.yaml
This is where you will start to set up the functionality that allows a user to choose which type of Pokémon they will learn about and who will receive the daily Slack message.
One of the PANDIUM.yaml's key purposes is to populate the Connections Settings page. That page allows users to customize how their tenant will run.
At the moment the PANDIUM.yaml in your Pokémon of the Day integration does not have any configurations, but the Academy has asked for these dynamic configs to be added: pokemon_type
and slack_user
Add
configs
with itsschema
anduischema
to your PANDIUM.yaml, so it looks like this:
Under
schema
properties
add the following:
The values in the $ref
for each of these properties determine the options for that config. E.g. the pokemon_type
config will have a dropdown menu on the Connections Settings page, and it will be filled with whatever is in #/definitions/pokemon_types
.
So let's add the definitions for pokemon_types
and slack_users
!
Make the
schema
definitions
look like this:
When you built the first iteration of the integration you saw that Pandium saves the standard out of a successful normal sync and passes it to the next run through context. Pandium also stores the standard out of a successful init sync.
When you add the init sync flow you will end it by printing a standard out which will look something like this:
Pandium will save that init sync's standard out and read it when displaying the Connections Settings page. It will replace each placeholder
with the content of the lists from your init sync's standard out.
You can read more about dynamic configs here.
Under
schema
required
addpokemon_type
andslack_user
.Add this
Section
element to theuischema
elements
:
Your PANDIUM.yaml should now look like the one here.
Let's take a look at how the connection settings page looks with this updated PANDIUM.yaml!
Last updated
Was this helpful?