Campaign
Campaign Service APIs
Facilitates campaign management - create, update, search or schedule campaigns.
Create's a campaign. On successful campaign creation, Ok response is returned.
The request object, containing all necessary information for creating an campaign and the request body metadata
Campaign created successfully.
Bad request
Internal server error
POST /campaigns/v1/_create HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 1098
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaign": {
"tenantId": "tenantA",
"name": "LLIN 2022",
"type": "LLIN",
"beneficiaryType": "HOUSEHOLD",
"eligibilityCriteria": "INSTRUCTIONS",
"isRegistrationAndDeliveryCombined": true,
"startDate": 1663218161,
"endDate": 1663218161,
"deliveryStrategy": "FIXED",
"deliveryProcedure": "INSTRUCTIONS",
"additionalFields": {},
"status": "CREATED",
"campaignSchedules": [
{
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA"
}
],
"campaignRounds": [
{
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA"
}
],
"disease": "MALARIA"
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"campaign": {
"id": "CAMPAIGN-ID-1",
"tenantId": "tenantA",
"name": "LLIN 2022",
"type": "LLIN",
"beneficiaryType": "HOUSEHOLD",
"eligibilityCriteria": "INSTRUCTIONS",
"isRegistrationAndDeliveryCombined": true,
"startDate": 1663218161,
"endDate": 1663218161,
"deliveryStrategy": "FIXED",
"deliveryProcedure": "INSTRUCTIONS",
"additionalFields": {},
"status": "CREATED",
"campaignSchedules": [
{
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
],
"campaignRounds": [
{
"campaignRoundId": "CAMPAIGN-ROUND-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
],
"disease": "MALARIA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
}
Update A Campaign, Ok response is returned.
The request object, containing all necessary information for updating an campaign and the request body metadata
Updated campaign successfully.
Bad request
Internal server error
POST /campaigns/v1/_update HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 1117
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaign": {
"id": "CAMPAIGN-ID",
"tenantId": "tenantA",
"name": "LLIN 2022",
"type": "LLIN",
"beneficiaryType": "HOUSEHOLD",
"eligibilityCriteria": "INSTRUCTIONS",
"isRegistrationAndDeliveryCombined": true,
"startDate": 1663218161,
"endDate": 1663218161,
"deliveryStrategy": "FIXED",
"deliveryProcedure": "INSTRUCTIONS",
"additionalFields": {},
"status": "CREATED",
"campaignSchedules": [
{
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA"
}
],
"campaignRounds": [
{
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA"
}
],
"disease": "MALARIA"
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"campaign": {
"id": "CAMPAIGN-ID-1",
"tenantId": "tenantA",
"name": "LLIN 2022",
"type": "LLIN",
"beneficiaryType": "HOUSEHOLD",
"eligibilityCriteria": "INSTRUCTIONS",
"isRegistrationAndDeliveryCombined": true,
"startDate": 1663218161,
"endDate": 1663218161,
"deliveryStrategy": "FIXED",
"deliveryProcedure": "INSTRUCTIONS",
"additionalFields": {},
"status": "CREATED",
"campaignSchedules": [
{
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
],
"campaignRounds": [
{
"campaignRoundId": "CAMPAIGN-ROUND-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
],
"disease": "MALARIA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
}
Search Campaigns Ok response is returned.
The request object, containing all necessary information for updating an campaign and the request body metadata
Fetched Search Campaigns.
Bad request
Internal server error
POST /campaigns/v1/_search HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 268
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignSearchCriteria": {
"id": "CAMPAIGN-ID",
"name": "LLIN 2022",
"type": "LLIN",
"status": "CREATED",
"limit": 0,
"offset": 0
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"totalCount": 1,
"campaigns": [
{
"id": "CAMPAIGN-ID-1",
"tenantId": "tenantA",
"name": "LLIN 2022",
"type": "LLIN",
"beneficiaryType": "HOUSEHOLD",
"eligibilityCriteria": "INSTRUCTIONS",
"isRegistrationAndDeliveryCombined": true,
"startDate": 1663218161,
"endDate": 1663218161,
"deliveryStrategy": "FIXED",
"deliveryProcedure": "INSTRUCTIONS",
"additionalFields": {},
"status": "CREATED",
"campaignSchedules": [
{
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
],
"campaignRounds": [
{
"campaignRoundId": "CAMPAIGN-ROUND-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
],
"disease": "MALARIA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
]
}
Create's a campaign schedule. On successful campaign schedule creation, Ok response is returned.
The request object, containing all necessary information for creating an campaign round and the request body metadata
Campaign schedule created successfully.
Bad request
Internal server error
POST /campaigns/schedule/v1/_create HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 386
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignSchedule": {
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA"
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"campaignRound": {
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1"
}
}
Update A Campaign, schedule Ok response is returned.
The request object, containing all necessary information for creating an campaign round and the request body metadata
Updated campaign schedule successfully.
Bad request
Internal server error
POST /campaigns/schedule/v1/_update HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 432
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignSchedule": {
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"noOfRounds": 4,
"durationBetweenRounds": 30,
"isRecurring": true,
"recurringFrequency": 4,
"durationAndFrequencyUnit": "DAYS",
"additionalFields": {},
"tenantId": "tenantA"
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"campaignRound": {
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1"
}
}
Search Campaigns schedule Ok response is returned.
The request object, containing all necessary information for updating an campaign and the request body metadata
Fetched Search Campaign schedule.
Bad request
Internal server error
POST /campaigns/schedule/v1/_search HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 305
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignScheduleSearchCriteria": {
"campaignId": "CAMPAIGN-ID",
"campaignScheduleId": "schedule-id",
"startDate": "EPOCH",
"endDate": "EPOCH",
"limit": 0,
"offset": 0
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"totalCount": 1,
"campaignRounds": [
{
"campaignScheduleId": "CAMPAIGN-SCHEDULE-ID-1"
}
]
}
Create's a campaign round. On successful campaign round creation, Ok response is returned.
The request object, containing all necessary information for creating an campaign round and the request body metadata
Campaign round created successfully.
Bad request
Internal server error
POST /campaigns/rounds/v1/_create HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 513
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignRound": {
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA"
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"campaignRound": {
"campaignRoundId": "CAMPAIGN-ROUND-ID-1"
}
}
Update A Campaign round Ok response is returned.
The request object, containing all necessary information for creating an campaign round and the request body metadata
Updated campaign round successfully.
Bad request
Internal server error
POST /campaigns/rounds/v1/_update HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 553
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignRound": {
"campaignRoundId": "CAMPAIGN-ROUND-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA"
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"campaignRound": {
"campaignRoundId": "CAMPAIGN-ROUND-ID-1"
}
}
Search Campaign rounds schedule Ok response is returned.
The request object, containing all necessary information for updating an campaign and the request body metadata
Fetched Search Campaign rounds.
Bad request
Internal server error
POST /campaigns/rounds/v1/_search HTTP/1.1
Host:
Content-Type: application/json
Accept: */*
Content-Length: 340
{
"requestInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"action": "text",
"did": "text",
"key": "text",
"msgId": "text",
"requesterId": "text",
"authToken": "text"
},
"campaignSearchCriteria": {
"campaignId": "CAMPAIGN-ID",
"campaignRoundId": "round-id",
"startDate": "EPOCH",
"endDate": "EPOCH",
"status": "INPROGRESS",
"boundaryId": "boundary-id",
"limit": 0,
"offset": 0
}
}
{
"responseInfo": {
"apiId": "text",
"ver": "text",
"ts": 1,
"resMsgId": "text",
"msgId": "text",
"status": "SUCCESSFUL"
},
"totalCount": 1,
"campaignRounds": [
{
"campaignRoundId": "CAMPAIGN-ROUND-ID-1",
"campaignId": "1",
"startDate": "EPOCH",
"endDate": "EPOCH",
"desiredTargets": {
"desiredTeamTarget": 100,
"desiredCoverageTarget": 0.8,
"desiredPopulationTarget": 1000
},
"achievedTargets": {
"achievedTeamTarget": 100,
"achievedCoverageTarget": 0.8,
"achievedPopulationTarget": 1000
},
"status": "INPROGRESS",
"boundaryId": "ID",
"additionalFields": {},
"tenantId": "tenantA",
"auditDetails": {
"createdBy": "text",
"lastModifiedBy": "text",
"createdTime": 1,
"lastModifiedTime": 1
}
}
]
}
Last updated
Was this helpful?