Thanks a lot. The solution worked for me.
Is there any way to connect all (!) pages of a workspace o an internal integration? Connecting every single page one by one manually defeats the purpose of scripting via the API.