Skip to main content

Request Vitas Sync

This job was provided by an OpenFn.org user via the job library API.

Metadata

Key Functions

alterState, dataPath, dataValue, each, post

Expression

alterState(state => {
const vitasSystemsToCheck = [
'vitas-1',
'thatMinistry-vitas-7',
'3',
'4',
'5',
]
return { ...state, data: { vitasSystemsToCheck } };
});

each(
dataPath('vitasSystemsToCheck[*]'),
post(state.configuration.inboxUrl, {
body: { "db": dataValue('database-id') },
})
);