GraphQL API Schema

Table of Contents

Query (RootQueryType)

FieldArgumentTypeDescription
campaigns[Campaign!]!Returns a public list of campaigns, filtered by title. Can be used to implement a campaign search box on a website.
titleStringFilter campaigns by title using LIKE format (% means any sequence of characters)
nameStringDEPRECATED: use campaign() to get one campaign. Filter campaigns by name (exact match). If found, returns list of 1 campaign, otherwise an empty list
idIntDEPRECATED: use campaign() to get one campaign. Select by id, Returns list of 1 result
campaignCampaignGet one campaign. If you have access to the campaign, as lead orpartner, you will get a private view of the campaign, otherwise, a publicview.
idIntGet by id
nameStringGet by name
actionPageActionPage!Get action page.Depending on your access (page owner, lead, instance admin),you will get private or public view of the page.
idIntGet action page by id.
nameStringGet action page by name the widget is displayed on
urlStringGet action page by url the widget is displayed on (DEPRECATED, use name)
exportActions[Action]!Export actions collected by org, optionally filtered by campaign
orgNameString!Organization name
campaignNameStringLimit results to campaign name
campaignIdIntLimit results to campaign id
startIntreturn only actions with id starting from this argument (inclusive)
afterDateTimereturn only actions created at date time from this argument (inclusive)
limitIntLimit the number of returned actions
onlyOptInBooleanOnly download opted in contacts and actions (default true)
onlyDoubleOptInBooleanOnly download double opted in contacts
includeTestingBooleanAlso include testing actions
currentUserUser!Get the current user, as determined by Authorization header
users[User!]!Select users from this instnace. Requires a manage users admin permission.
selectSelectUserFilter users
orgPrivateOrg!Organization api (authenticated)
nameString!Name of organisation

Mutation (RootMutationType)

FieldArgumentTypeDescription
upsertCampaignCampaign!Upserts a campaign.Creates or appends campaign and it's action pages. In case of append, itwill change the campaign with the matching name, and action pages withmatching names. It will create new action pages if you pass new names. NoAction Pages will be removed (principle of not removing signature data).
orgNameString!Org name
inputCampaignInput!Campaign content to be upserted
updateCampaignCampaign!Updates an existing campaign.
idIntId of campaign to update
nameStringName of campaign to update (alterantive to id)
inputCampaignInput!Campaign content to be updated
addCampaignCampaign!Add a new campaign
orgNameString!Org that is lead of this campaign
inputCampaignInput!Campaign content to be added
deleteCampaignStatus!Delete a campaign.Deletion will be blocked if there are action pages with personal data (we never remove personal data unless via GDPR).
idIntby id
nameStringby name
externalIdIntby external_id
updateActionPageActionPage!Update an Action Page
idIntid of page to update
nameStringname of page to update
inputActionPageInput!content of page to be update
copyActionPageActionPage!Adds a new Action Page based on another Action Page. Intended to be used tocreate a partner action page based off lead's one. Copies: campaign, locale, config, delivery flag
orgNameString!Org owner of new Action Page
nameString!New Action Page name
fromNameString!Name of Action Page this one is cloned from
copyCampaignActionPageActionPage!Adds a new Action Page based on latest Action Page from campaign. Intended to be used tocreate a partner action page based off lead's one. Copies: campaign, locale, config, delivery flag
orgNameString!Org owner of new Action Page
nameString!New Action Page name
fromCampaignNameString!Name of Campaign from which the page is copied
addActionPageActionPage!
orgNameString!Org owner of new Action Page
campaignNameString!Name of campaign where page is created
inputActionPageInput!Action Page attributes
launchActionPageLaunchActionPageResult!Sends a request to lead to set the page to live=true
nameString!Action Page name
messageStringOptional message for approver
deleteActionPageStatus!Delete an action page
idIntAction Page id
nameStringAction Page name
addActionContactReference!Adds an action referencing contact data via contactRef
actionPageIdInt!
actionActionInput!Action data
contactRefID!Contact reference
trackingTrackingInputTracking codes (UTM_*)
addActionContactContactReference!Adds an action with contact data
actionPageIdInt!
actionActionInput!Action data
contactContactInput!GDPR communication opt
privacyConsentInput!Signature action data
trackingTrackingInputTracking codes (UTM_*)
contactRefIDLinks previous actions with just reference to this supporter data
linkActionsContactReference!Link actions with refs to contact with contact reference
actionPageIdInt!Action Page id
contactRefID!Contact reference
linkRefs[String!]Link actions with these references (if unlinked to supporter)
requeueActionsRequeueResult!Requeue actions into one of processing destinations
orgNameString!Organization name
ids[Int!]Action Ids
queueQueue!Destination queue
addOrgUserChangeUserStatus!Add user to org by email
orgNameString!Org name
inputOrgUserInput!User content
inviteOrgUserConfirm!Invite an user to org by email (can be not yet user!)
orgNameString!org name to invite to
inputOrgUserInput!user membership data
messageStringOptional message for invited user
updateOrgUserChangeUserStatus!
orgNameString!update user membership data
inputOrgUserInput!user membership data
deleteOrgUserDeleteUserResult
orgNameString!delete user from this org
emailString!users email
updateUserUser!Update (current) user details
inputUserDetailsInput!Input values to update in user
idIntAdmin can use user id to specify user to update
emailStringAdmin can use user email to specify user to update
resetApiTokenString!
addOrgOrg!Add an org. Calling user will become it's owner.
inputOrgInput!Contet of the org to be added
deleteOrgStatus!Delete an org
nameString!Name of organisation to be deleted
updateOrgPrivateOrg!Update an org
nameString!Name of organisation, used for lookup, can't be used to change org name
inputOrgInput!Content of org to be updated
updateOrgProcessingPrivateOrg!Update org processing settings
nameString!Name of the org (to rename it)
emailBackendServiceNameUse a particular owned service type for sending emails
emailFromStringEnvelope FROM email when sending emails
supporterConfirmBooleanIs the supporter required to double opt in their action (and associated personal data)?
supporterConfirmTemplateStringThe email template name that will be used to send the action DOI request
doiThankYouBooleanShould the thank you email be only send when email consent doi is required (and contain it)
customSupporterConfirmBooleanShould proca put action in a custom queue, so an external service can do this?
customActionConfirmBooleanShould proca put action in a custom queue, so an external service can do this?
customActionDeliverBooleanShould proca put action in custom delivery queue, so an external service can sync it?
customEventDeliverBooleanShould proca put events in custom delivery queue, so an external service can sync it?
eventBackendServiceNameUse a particular owned service type for sending events
storageBackendServiceNameUse a particular owned service type for uploading files
detailBackendServiceNameUse a particular owned service type for looking up supporters in CRM
pushBackendServiceNameUse a particular owned service type for sending actions
joinOrgJoinOrgResult!Try becoming a staffer of the org
nameString!Join the org of this name
generateKeyKeyWithPrivate!Generate a new encryption key in org
orgNameString!Name of organisation
inputGenKeyInput!
addKeyKey!Add a key to encryption keys
orgNameString!Name of organisation
inputAddKeyInput!key content
activateKeyActivateKeyResult!A separate key activate operation, because you also need to add the key to receiving system before it is used
orgNameString!
idInt!Key id
upsertTemplateStatusUpsert an email tempalte to be used for sending various emails.It belongs to org and is identified by (name, locale), so you can have multiple "thank_you" templates for different languages.
orgNameString!Add email tempalte to which org
inputEmailTemplateInput!Email template content
upsertServiceService!Insert or update a service for an org, using id to to update a particular one
orgNameString!Owner org
idIntId to select service to be updated
inputServiceInput!Content of service
addStripePaymentIntentJson!Stripe API - add a stripe payment intent, when donating to the action page specified by id
actionPageIdInt!Donating to this page
inputStripePaymentIntentInput!payment intent content
contactRefIDContact reference of donating supporter
testingBooleanUse test stripe api keys
addStripeSubscriptionJson!Stripe API - add a stripe subscription, when donating to the action page specified by id
actionPageIdInt!Donating to this page
inputStripeSubscriptionInput!subscription intent content
contactRefIDContact reference of donating supporter
testingBooleanUse test stripe api keys
addStripeObjectJson!Create stripe object using Stripe key associated with action page owning org.Pass any of paymentIntent, subscription, customer, price json params to be sent as-is to Stripe API. The result is a JSON returned by Stripe API or a GraphQL Error object.If you provide customer along payment intent or subscription, it will be first created, then their id will be added to params for the payment intent or subscription, so you can pack 2 Stripe API calls into one. You can do the same with price object in case of a subscription.
actionPageIdInt!
paymentIntentJsonParameters for Stripe Payment Intent creation
subscriptionJsonParameters for Stripe Subscription creation
customerJsonParameters for Stripe Customer creation
priceJsonParameters for Stripe Price creation
testingBooleanUse test stripe api keys
acceptOrgConfirmConfirmResult!Accept a confirm on behalf of organisation.
nameString!Org name
confirmConfirmInput!Confirm content
rejectOrgConfirmConfirmResult!Reject a confirm on behalf of organisation.
nameString!Org name
confirmConfirmInput!Confirm data
acceptUserConfirmConfirmResult!Accept a confirm by user
confirmConfirmInput!Confirm data
rejectUserConfirmConfirmResult!Reject a confirm by user
confirmConfirmInput!Confirm data
upsertTargets[PrivateTarget]!Upsert multiple targets at once.external_id is used to decide if new target record is added, or existing one is updated.
targets[TargetInput!]!List of targets
campaignIdInt!Id of campaign these targets are added to
replaceBooleanRemove targets not existing in this upsert (if false, upsert will merge with omitted targets)

Objects

Action

FieldArgumentTypeDescription
actionIdInt!Id of action
createdAtNaiveDateTime!Timestamp of creation
actionTypeString!Action type
contactContact!supporter contact data
customFieldsJson!Action custom fields (as stringified JSON)
fields ⚠️[CustomField!]!Deprecated, use customFields

⚠️ DEPRECATED

use custom_fields
trackingTrackingUTM codes
campaignCampaign!Campaign this action was collected in
actionPageActionPage!Action page this action was collected at
privacyConsent!Consents, privacy data of this action
donationDonationDonation specific data

ActionCustomFields

FieldArgumentTypeDescription
actionIdInt!id of action
actionTypeString!type of action
insertedAtNaiveDateTime!creation timestamp
areaStringarea of supporter that did the action
customFieldsJson!custom fields as stringified json
fields ⚠️[CustomField!]!

⚠️ DEPRECATED

use custom_fields

ActionTypeCount

Count of actions for particular action type

FieldArgumentTypeDescription
actionTypeString!action type
countInt!count of actions of action type

ActivateKeyResult

FieldArgumentTypeDescription
statusStatus!

ApiToken

Api token metadata

FieldArgumentTypeDescription
expiresAtNaiveDateTime!

AreaCount

Count of actions for particular action type

FieldArgumentTypeDescription
areaString!area
countInt!count of supporters in this area

CampaignMtt

FieldArgumentTypeDescription
startAtDateTime!This is first day and start hour of the campaign. Note, every day of the campaign the start hour will be same.
endAtDateTime!This is last day and end hour of the campaign. Note, every day of the campaign the end hour will be same.
messageTemplateStringIf email templates are used to create MTT, use this template (works like thank you email templates).Otherwise, the raw text that is send with MTT action will make a plain text email.
testEmailStringA test target email (yourself) where test mtt actions will be sent (instead to real targets)

CampaignStats

Campaign statistics

FieldArgumentTypeDescription
supporterCountInt!Unique action tagers count
supporterCountByArea[AreaCount!]!Unique action takers by area
supporterCountByOrg[OrgCount!]!Unique action takers by org
supporterCountByOthersInt!Unique supporter count not including the ones collected by org_name
orgNameString!Org name to exclude from counting supporters
actionCount[ActionTypeCount!]!Action counts per action types (with duplicates)

ChangeUserStatus

FieldArgumentTypeDescription
statusStatus!

Confirm

FieldArgumentTypeDescription
codeString!Secret code/PIN of the confirm
emailStringEmail the confirm is sent to
messageStringMessage attached to the confirm
objectIdIntObject id that confirmable action refers to
creatorUserWho created the confirm

ConfirmResult

FieldArgumentTypeDescription
statusStatus!Status of Confirm: Success, Confirming (waiting for confirmation), Noop
actionPageActionPageAction page if its an object of confirm
campaignCampaignCampaign page if its an object of confirm
orgOrgOrg if its an object of confirm
messageStringA message attached to the confirm

GDPR consent data for this org

FieldArgumentTypeDescription
optInBooleancommunication (email) opt-in
givenAtNaiveDateTime!Consent timestamp
emailStatusEmailStatus!Email status, whether it's normal, DOI, or bouncing
emailStatusChangedNaiveDateTimeWhen did the email status change last time
withConsentBoolean!This action contained consent (if false, it could be a share action that is attached to another action containing a consent)

Contact

FieldArgumentTypeDescription
contactRefID!Contact ref (fingerprint) of supporter
payloadString!Stringified json with PII optionally encrypted
nonceStringEncryption nonce value
publicKeyKeyIdsPublic key used to encrypt this action
signKeyKeyIdsSigning key used to encrypt this action

ContactReference

FieldArgumentTypeDescription
contactRefString!Contact's reference
firstNameStringContacts first name

CustomField

Custom field with a key and value.

FieldArgumentTypeDescription
keyString!
valueString!

DeleteUserResult

FieldArgumentTypeDescription
statusStatus!

Donation

FieldArgumentTypeDescription
schemaDonationSchema
amountInt!Provide amount of this donation, in smallest units for currency
currencyString!Provide currency of this donation
payloadJson!Donation data
frequencyUnitDonationFrequencyUnit!Donation frequency unit

JoinOrgResult

FieldArgumentTypeDescription
statusStatus!Result of joining - succes or pending confirmation
orgOrg!Org that was joined

Key

Encryption or sign key with integer id (database)

FieldArgumentTypeDescription
idInt!Key id
publicString!Public part of the key (base64url)
nameString!Name of the key (human readable)
activeBoolean!Is it active?
expiredBoolean!Is it expired?
expiredAtNaiveDateTimeWhen the key was expired, in UTC

KeyIds

FieldArgumentTypeDescription
idInt!Key id
publicString!Public part of the key (base64url)

KeyWithPrivate

FieldArgumentTypeDescription
idInt!Key id
publicString!Public part of the key (base64url)
privateString!Private (Secret) part of the key (base64url)
nameString!Name of the key (human readable)
activeBoolean!Is it active?
expiredBoolean!Is it expired?
expiredAtNaiveDateTimeWhen the key was expired, in UTC

LaunchActionPageResult

FieldArgumentTypeDescription
statusStatus!

OrgCount

Count of supporters for particular org

FieldArgumentTypeDescription
orgOrg!org
countInt!count of supporters registered by org

OrgUser

FieldArgumentTypeDescription
emailString!
roleString!Role in an org
createdAtNaiveDateTime!Date and time the user was created on this instance
joinedAtNaiveDateTime!Date and time when user joined org
lastSigninAtNaiveDateTimeWill be removed

Partnership

FieldArgumentTypeDescription
orgOrg!Partner org
actionPages[ActionPage!]!Partner's pages that are part of this campaign (can be more, eg: multiple languages)
launchRequests[Confirm!]!Join/Launch requests of this partner
launchRequesters[User!]!The partner staffers who initiated a request

PersonalData

FieldArgumentTypeDescription
contactSchemaContactSchema!Schema for contact personal information
supporterConfirmBoolean!Email opt in enabled
supporterConfirmTemplateStringEmail opt in template name
highSecurityBoolean!High data security enabled
doiThankYouBoolean!Only send thank you emails to opt-ins

PrivateActionPage

FieldArgumentTypeDescription
idInt!Id
localeString!Locale for the widget, in i18n format
nameString!Name where the widget is hosted
thankYouTemplateStringThank you email templated of this Action Page
thankYouTemplateRefStringA reference to thank you email template of this ActionPage
liveBoolean!Is live?
journey ⚠️[String!]!List of steps in journey

⚠️ DEPRECATED

moved under config
configJson!Config JSON of this action page
campaignCampaign!Campaign this action page belongs to.
orgOrg!Org the action page belongs to
extraSupportersInt!Extra supporters, a number added to deduplicated supporter count. Cannot be added to per-area or per-action_type counts.
deliveryBoolean!Action page collects also opt-out actions, to deliver them to authorities.If false, the opt-outs will fallback to lead (we never trash data with opt-outs)
supporterConfirmTemplateStringEmail template to confirm supporter (DOI)
locationStringLocation of the widget as last seen in HTTP REFERER header
statusActionPageStatusStatus of action page - STANDBY (ready to get actions), ACTIVE (collecting actions), STALLED (actions not coming any more)

PrivateCampaign

FieldArgumentTypeDescription
idInt!Campaign id
externalIdIntExternal ID (if set)
nameString!Internal name of the campaign
titleString!Full, official name of the campaign
contactSchemaContactSchema!Schema for contact personal information
configJson!Custom config map
statsCampaignStats!Statistics
orgOrg!Lead org
actionsPublicActionsResult!Fetch public actions. Can be used to display recent comments for example.To allow-list action fields to be public, `campaign.public_actions` must be set to a list of strings in formaction_type:custom_field_name, eg: `["signature:comment"]`. XXX this cannot be set in API, you need to set in backend.
actionTypeString!Specify action type to return
limitInt!Limit the number of returned actions, default is 10, max is 100)
targets[Target]List MTT targets of this campaign
forceDeliveryBoolean!Campaign onwer collects opt-out actions for delivery even if campaign partner is delivering
actionPages[PrivateActionPage!]!Action Pages of this campaign that are accessible to current user
partnerships[Partnership!]List of partnerships and requests to join partnership
mttCampaignMttMTT configuration

PrivateOrg

FieldArgumentTypeDescription
nameString!Organisation short name
titleString!Organisation title (human readable name)
configJson!config
idInt!Organization id
personalDataPersonalData!Personal data settings for this org
keys[Key!]!Encryption keys
selectSelectKey
keyKey!Get encryption key
selectSelectKey!Parameters to select the key by
services[Service]!Services of this org
selectSelectServiceParameters to select the key by
users[OrgUser]!Users of this org
processingProcessing!Action processing settings for this org
campaigns[Campaign!]!List campaigns this org is leader or partner of
selectSelectCampaign
actionPages[ActionPage!]!List action pages this org has
selectSelectActionPage
actionPageActionPage!Get one page belonging to this org
idIntId of page
nameStringName of page
campaignCampaign!DEPRECATED: use campaign() in API root. Get campaign this org is leader or partner of by id
idInt!

PrivateTarget

FieldArgumentTypeDescription
idString!
nameString!Name of target
externalIdString!unique external_id of target, used to upsert target
localeStringLocale of this target (in which language do they read emails?)
areaStringArea of the target
fieldsJsonCustom fields, stringified json
emails[TargetEmail]!Email list of this target

Processing

FieldArgumentTypeDescription
emailFromStringEnvelope FROM email when sending emails
emailBackendServiceNameUse a particular owned service type for sending emails
supporterConfirmBoolean!Is the supporter required to double opt in their action (and associated personal data)?
supporterConfirmTemplateStringThe email template name that will be used to send the action DOI request
doiThankYouBoolean!Only send thank you emails to opt-ins
customSupporterConfirmBoolean!Should proca put action in a custom queue, so an external service can do this?
customActionConfirmBoolean!Should proca put action in a custom queue, so an external service can do this?
customActionDeliverBoolean!Should proca put action in custom delivery queue, so an external service can sync it?
customEventDeliverBoolean!Should proca put events in custom delivery queue, so an external service can sync it?
eventBackendServiceNameUse a particular owned service type for sending events
pushBackendServiceNameUse a particular owned service type for sending actions
storageBackendServiceNameUse a particular owned service type for uploading files
detailBackendServiceNameUse a particular owned service type for looking up supporters in CRM
emailTemplates[String!]Email templates. (warn: contant is not available to fetch)

PublicActionPage

FieldArgumentTypeDescription
idInt!Id
localeString!Locale for the widget, in i18n format
nameString!Name where the widget is hosted
thankYouTemplateStringThank you email templated of this Action Page
thankYouTemplateRefStringA reference to thank you email template of this ActionPage
liveBoolean!Is live?
journey ⚠️[String!]!List of steps in journey

⚠️ DEPRECATED

moved under config
configJson!Config JSON of this action page
campaignCampaign!Campaign this action page belongs to.
orgOrg!Org the action page belongs to

PublicActionsResult

Result of actions query

FieldArgumentTypeDescription
fieldKeys[String!]Custom field keys which are public
list[ActionCustomFields]List of actions custom fields

PublicCampaign

FieldArgumentTypeDescription
idInt!Campaign id
externalIdIntExternal ID (if set)
nameString!Internal name of the campaign
titleString!Full, official name of the campaign
contactSchemaContactSchema!Schema for contact personal information
configJson!Custom config map
statsCampaignStats!Statistics
orgOrg!Lead org
actionsPublicActionsResult!Fetch public actions. Can be used to display recent comments for example.To allow-list action fields to be public, `campaign.public_actions` must be set to a list of strings in formaction_type:custom_field_name, eg: `["signature:comment"]`. XXX this cannot be set in API, you need to set in backend.
actionTypeString!Specify action type to return
limitInt!Limit the number of returned actions, default is 10, max is 100)
targets[Target]List MTT targets of this campaign

PublicOrg

FieldArgumentTypeDescription
nameString!Organisation short name
titleString!Organisation title (human readable name)
configJson!config

PublicTarget

FieldArgumentTypeDescription
idString!
nameString!Name of target
externalIdString!unique external_id of target, used to upsert target
localeStringLocale of this target (in which language do they read emails?)
areaStringArea of the target
fieldsJsonCustom fields, stringified json

RequeueResult

FieldArgumentTypeDescription
countInt!Count of actions selected for requeueing
failedInt!Count of actions that could not be requeued

RootSubscriptionType

FieldArgumentTypeDescription
actionPageUpsertedActionPage!
orgNameString

Service

FieldArgumentTypeDescription
idInt!Id
nameServiceName!Service name (type)
hostStringHostname of service, but can be used as any "container" of the service. For AWS, contains a region.
userStringUser, Account id, client id, whatever your API has
pathStringA sub-selector of a resource. Can be url path, but can be something like AWS bucket name

TargetEmail

FieldArgumentTypeDescription
emailString!Email of target
emailStatusEmailStatus!The status of email (normal or bouncing etc)
errorStringAn error received when bouncing email was reported

Tracking

Tracking codes (UTM params)

FieldArgumentTypeDescription
sourceString!
mediumString!
campaignString!
contentString!

User

FieldArgumentTypeDescription
idInt!Id of user
emailString!Email of user
phoneStringPhone
pictureUrlStringUrl to profile picture
jobTitleStringJob title
apiTokenApiTokenUsers API token (to check expiry)
isAdminBoolean!Is user an admin?
roles[UserRole!]!user's roles in orgs

UserRole

FieldArgumentTypeDescription
orgOrg!Org this role is in
roleString!Role name

Inputs

ActionInput

Custom field added to action. For signature it can be contact, for mail it can be subject and body

FieldTypeDescription
actionTypeString!Action Type
customFieldsJsonCustom fields added to action
donationDonationActionInputDonation payload
mttMttActionInputMTT payload
testingBooleanTest mode

ActionPageInput

ActionPage input

FieldTypeDescription
nameStringUnique NAME identifying ActionPage.Does not have to exist, must be unique. Can be a 'technical' identifierscoped to particular organization, so it does not have to change when theslugs/names change (eg. some.org/1234). However, frontend Widget canask for ActionPage by it's current location.href (but without https://), in which case it is usefulto make this url match the real widget location.
localeString2-letter, lowercase, code of ActionPage language
thankYouTemplateStringThank you email template of this ActionPage
supporterConfirmTemplateStringSupporter confirm email template of this ActionPage
extraSupportersIntExtra supporter count. If you want to add a number of signatories you have offline or kept in another system, you can specify the number here.
configJsonJSON string containing Action Page config
deliveryBooleanCollected PII is processed even with no opt-in

AddKeyInput

FieldTypeDescription
nameString!Name of the key
publicString!Public part of the key (base64url)

AddressInput

Address type which can hold different addres fields.

FieldTypeDescription
countryStringCountry code (two-letter).
postcodeStringPostcode, in format correct for country locale
localityStringLocality, which can be a city/town/village
regionStringRegion, being province, voyevodship, county
streetStringStreet name
streetNumberStringStreet number

CampaignInput

Campaign content changed in mutations

FieldTypeDescription
nameStringCampaign short name
externalIdIntCampaign external_id. If provided, it will be used to find campaign. Can be used to rename a campaign
titleStringCampaign human readable title
contactSchemaContactSchemaSchema for contact personal information
configJsonCustom config as stringified JSON map
actionPages[ActionPageInput!]Action pages of this campaign
mttCampaignMttInputMTT configuration

CampaignMttInput

FieldTypeDescription
startAtDateTimeThis is first day and start hour of the campaign. Note, every day of the campaign the start hour will be same.
endAtDateTimeThis is last day and end hour of the campaign. Note, every day of the campaign the end hour will be same.
messageTemplateStringIf email templates are used to create MTT, use this template (works like thank you email templates).Otherwise, the raw text that is send with MTT action will make a plain text email.
testEmailStringA test target email (yourself) where test mtt actions will be sent (instead to real targets)

ConfirmInput

FieldTypeDescription
codeString!secret code of this confirm
emailStringemail that confirm was assigned for
objectIdIntobject_id that this confirm refers to

ConsentInput

GDPR consent data structure

FieldTypeDescription
optInBooleanHas contact consented to receiving communication from widget owner? Null: not asked
leadOptInBooleanOpt in to the campaign leader

ContactInput

Contact information

FieldTypeDescription
nameStringFull name
firstNameStringFirst name (when you provide full name split into first and last)
lastNameStringLast name (when you provide full name split into first and last)
emailStringEmail
phoneStringContacts phone number
birthDateDateDate of birth in format YYYY-MM-DD
addressAddressInputContacts address
nationalityNationalityInputNationality information

CustomFieldInput

Custom field with a key and value. Both are strings.

FieldTypeDescription
keyString!
valueString!
transientBooleanUnused. To mark action_type/key as transient, use campaign.transient_actions list

DonationActionInput

FieldTypeDescription
schemaDonationSchemaProvide payload schema to validate, eg. stripe_payment_intent
amountIntProvide amount of this donation, in smallest units for currency
currencyStringProvide currency of this donation
frequencyUnitDonationFrequencyUnitHow often is the recurring donation collected
payloadJson!Custom JSON data

EmailTemplateInput

FieldTypeDescription
nameString!template name
localeStringtemplate locale
subjectStringSubject text
htmlStringHtml part body
textStringPlaintext part body

GenKeyInput

FieldTypeDescription
nameString!Name of the key

MttActionInput

FieldTypeDescription
subjectStringSubject line
bodyStringBody
targets[String!]!Target ids
files[String!]Files to attach (images allowed)

NationalityInput

FieldTypeDescription
countryString!Nationality / issuer of id document
documentTypeStringDocument type
documentNumberStringDocument serial id/number

OrgInput

FieldTypeDescription
nameStringName used to rename
titleStringOrganisation title (human readable name)
contactSchemaContactSchemaSchema for contact personal information
supporterConfirmBooleanEmail opt in enabled
supporterConfirmTemplateStringEmail opt in template name
doiThankYouBooleanOnly send thank you emails to opt-ins
configJsonConfig

OrgUserInput

FieldTypeDescription
emailString!Email of user
roleString!Role name of user in this org

SelectActionPage

FieldTypeDescription
campaignIdIntFilter by campaign Id

SelectCampaign

FieldTypeDescription
titleLikeString
orgNameString

SelectKey

FieldTypeDescription
idIntKey id
activeBooleanOnly active
publicStringKey having this public part

SelectService

FieldTypeDescription
nameServiceName

SelectUser

Criteria to filter users

FieldTypeDescription
idInt
emailStringUse % as wildcard
orgNameStringExact org name

ServiceInput

FieldTypeDescription
nameServiceName!Service name (type)
hostStringHostname of service, but can be used as any "container" of the service. For AWS, contains a region.
userStringUser, Account id, client id, whatever your API has
passwordStringPassword, key, secret or whatever your API has as secret credential
pathStringA sub-selector of a resource. Can be url path, but can be something like AWS bucket name

StripePaymentIntentInput

FieldTypeDescription
amountInt!Amount of payment
currencyString!Currency ofo payment
paymentMethodTypes[String!]Stripe payment method type

StripeSubscriptionInput

FieldTypeDescription
amountInt!Amount of payment
currencyString!Currency ofo payment
frequencyUnitDonationFrequencyUnit!how often is recurrent payment made?

TargetEmailInput

FieldTypeDescription
emailString!Email of target

TargetInput

FieldTypeDescription
nameStringName of target
externalIdString!unique external_id of target, used to upsert target
localeStringLocale of this target (in which language do they read emails?)
areaStringArea of the target
fieldsJsonCustom fields, stringified json
emails[TargetEmailInput!]Email list of this target

TrackingInput

Tracking codes, utm medium/campaign/source default to 'unknown', content to empty string

FieldTypeDescription
sourceString
mediumString
campaignString
contentString
locationStringAction page location. Url from which action is added. Must contain schema, domain, (port), pathname

UserDetailsInput

FieldTypeDescription
pictureUrlStringUsers profile pic url
jobTitleStringJob title
phoneStringPhone

Enums

ActionPageStatus

ValueDescription
STANDBYThis action page is ready to receive first action or is stalled for over 1 year
ACTIVEThis action page received actions lately
STALLEDThis action page did not receive actions lately

ContactSchema

ValueDescription
BASIC
POPULAR_INITIATIVE
ECI
IT_CI

DonationFrequencyUnit

ValueDescription
ONE_OFF
WEEKLY
MONTHLY
DAILY

DonationSchema

ValueDescription
STRIPE_PAYMENT_INTENT

EmailStatus

ValueDescription
NONEAn unused email. (Warning: Or used, but we do not store the fact that emails are delivered ok)
DOUBLE_OPT_INThe user has received a DOI on this email and accepted it
BOUNCEThis email was used and bounced
BLOCKEDThis email was used and blocked
SPAMThis email was used and marked spam
UNSUBThis email was used and user unsubscribed

Queue

ValueDescription
EMAIL_SUPPORTERQueue of thank you email sender worker
CUSTOM_SUPPORTER_CONFIRMa custom queue of action that needs DOI
CUSTOM_ACTION_CONFIRMa custom queue of action that needs moderation
CUSTOM_ACTION_DELIVERa custom queue of actions to sync to CRM
SQSQueue of SQS sync worker
WEBHOOKQueue of webhook sync worker

ServiceName

ValueDescription
SESAWS SES to send emails
SQSAWS SQS to process messages
MAILJETMailjet to send emails
SMTPSMTP to send emails
WORDPRESSWordpress HTTP API
STRIPEStripe to process donations
TEST_STRIPEStripe test account to test donations
WEBHOOKHTTP POST webhook
SYSTEMUse a service that instance org is using
SUPABASESupabase to store files

Status

ValueDescription
SUCCESSOperation completed succesfully
CONFIRMINGOperation awaiting confirmation
NOOPOperation had no effect (already done)

Scalars

Boolean

The Boolean scalar type represents true or false.

Date

The Date scalar type represents a date. The Date appears in a JSON response as an ISO8601 formatted string, without a time component.

DateTime

The DateTime scalar type represents a date and time in the UTC timezone. The DateTime appears in a JSON response as an ISO8601 formatted string, including UTC timezone ("Z"). The parsed date and time string will be converted to UTC if there is an offset.

ID

The ID scalar type represents a unique identifier, often used to refetch an object or as key for a cache. The ID type appears in a JSON response as a String; however, it is not intended to be human-readable. When expected as an input type, any string (such as "4") or integer (such as 4) input value will be accepted as an ID.

Int

The Int scalar type represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.

Json

NaiveDateTime

The Naive DateTime scalar type represents a naive date and time without timezone. The DateTime appears in a JSON response as an ISO8601 formatted string.

String

The String scalar type represents textual data, represented as UTF-8 character sequences. The String type is most often used by GraphQL to represent free-form human-readable text.

Interfaces

ActionPage

FieldArgumentTypeDescription
idInt!Id
localeString!Locale for the widget, in i18n format
nameString!Name where the widget is hosted
thankYouTemplateStringThank you email templated of this Action Page
thankYouTemplateRefStringA reference to thank you email template of this ActionPage
liveBoolean!Is live?
journey ⚠️[String!]!List of steps in journey

⚠️ DEPRECATED

moved under config
configJson!Config JSON of this action page
campaignCampaign!Campaign this action page belongs to.
orgOrg!Org the action page belongs to

Campaign

FieldArgumentTypeDescription
idInt!Campaign id
externalIdIntExternal ID (if set)
nameString!Internal name of the campaign
titleString!Full, official name of the campaign
contactSchemaContactSchema!Schema for contact personal information
configJson!Custom config map
statsCampaignStats!Statistics
orgOrg!Lead org
actionsPublicActionsResult!Fetch public actions. Can be used to display recent comments for example.To allow-list action fields to be public, `campaign.public_actions` must be set to a list of strings in formaction_type:custom_field_name, eg: `["signature:comment"]`. XXX this cannot be set in API, you need to set in backend.
actionTypeString!Specify action type to return
limitInt!Limit the number of returned actions, default is 10, max is 100)
targets[Target]List MTT targets of this campaign

Org

FieldArgumentTypeDescription
nameString!Organisation short name
titleString!Organisation title (human readable name)
configJson!config

Target

FieldArgumentTypeDescription
idString!
nameString!Name of target
externalIdString!unique external_id of target, used to upsert target
localeStringLocale of this target (in which language do they read emails?)
areaStringArea of the target
fieldsJsonCustom fields, stringified json

Done in 0.18s.