{"openapi":"3.0.0","paths":{"/oauth/token":{"post":{"description":"Generate the OAuth Token to authorize further requests.","operationId":"getToken","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenRequestDto"}}}},"responses":{"200":{"description":"Successful operation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponseDto"}}}},"400":{"description":"Bad request"},"403":{"description":"Accessing unauthorized instances"}},"summary":"Generate OAuth Token","tags":["Authentication"]}},"/v1/reporting/instances":{"get":{"description":"Get all instances accessible by the provided API credentials","operationId":"getAllowedInstances","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"$ref":"#/components/schemas/InstancesResponseDto"},"meta":{"nullable":true,"example":null}}}]}}}}},"summary":"","tags":["Instance Level"]}},"/v1/reporting/instance/details":{"get":{"description":"Get details for associated instance available for the provided API credentials. If the credentials have access to multiple instances, the first one will be returned, consider using `GET /instances/details` to get details for all instances.","operationId":"getInfoAboutInstanceAndCampaigns","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"$ref":"#/components/schemas/InstanceDetailsResponseDto"},"meta":{"nullable":true,"example":null}}}]}}}}},"summary":"","tags":["Instance Level"]}},"/v1/reporting/instances/details":{"get":{"description":"Get details for all the associated instances available for the provided API credentials","operationId":"getInfoAboutMultipleInstancesAndCampaigns","parameters":[],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/InstanceDetailsResponseDto"}},"meta":{"nullable":true,"example":null}}}]}}}}},"summary":"","tags":["Instance Level"]}},"/v1/reporting/instance/performance":{"get":{"description":"Get instance performance details.","operationId":"getInstancePerformance","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"$ref":"#/components/schemas/InstancePerformanceResponseDto"},"meta":{"nullable":true,"example":null}}}]}}}}},"summary":"","tags":["Instance Level"]}},"/v1/reporting/instance/performance-over-time":{"get":{"description":"Get instance performance details over time.","operationId":"getPerformanceOverTime","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}},{"name":"pageSize","required":false,"in":"query","description":"Number of items per page","schema":{"default":50,"type":"number"}},{"name":"pageNumber","required":false,"in":"query","description":"The page you would like to get data for","schema":{"default":1,"type":"number"}},{"name":"granularity","required":false,"in":"query","schema":{"default":"month","type":"string","enum":["year","quarter","month","week","day"]}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiGranularResponseDto"},{"properties":{"data":{"type":"array","items":{"type":"object","properties":{"metrics":{"$ref":"#/components/schemas/InstancePerformanceOverTimeMetricsDto"},"date":{"$ref":"#/components/schemas/PerformanceOverTimeDateDto"}}}}}}]}}}}},"summary":"","tags":["Instance Level"]}},"/v1/reporting/campaign/performance":{"get":{"description":"Get campaign performance details.","operationId":"getCampaignPerformance","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}},{"name":"pageSize","required":false,"in":"query","description":"Number of items per page","schema":{"default":50,"type":"number"}},{"name":"pageNumber","required":false,"in":"query","description":"The page you would like to get data for","schema":{"default":1,"type":"number"}},{"name":"sortProperty","required":false,"in":"query","description":"sortProperty must be one of the following values: engagements, impressions, engagementRate, impressionsPerPost, estimatedValueGenerated, estimatedRoi, reach, cpe, cpm, firstPostDate, lastPostDate, estimatedContentCost, campaignTitle, postsCount, influencersCount, clicks, trackingLinksClicks, trackingLinksConversions, trackingLinksConversionValue, affiliateLinksClicks, affiliateLinksConversions, affiliateLinksConversionRate, affiliateLinksSales, affiliateLinksComissionEarned, affiliateLinksRoi","schema":{"type":"string"}},{"name":"sortDirection","required":false,"in":"query","description":"ASC or DESC","schema":{"default":"DESC","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/CampaignPerformanceResponseDto"}}}}]}}}}},"summary":"","tags":["Campaign Level"]}},"/v1/reporting/network/performance":{"get":{"description":"Get social networks performance details.","operationId":"getNetworkPerformance","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}},{"name":"pageSize","required":false,"in":"query","description":"Number of items per page","schema":{"default":50,"type":"number"}},{"name":"pageNumber","required":false,"in":"query","description":"The page you would like to get data for","schema":{"default":1,"type":"number"}},{"name":"sortProperty","required":false,"in":"query","description":"sortProperty must be one of the following values: engagements, impressions, engagementRate, impressionsPerPosts, engagementsPerPosts, postsCount","schema":{"type":"string"}},{"name":"sortDirection","required":false,"in":"query","description":"ASC or DESC","schema":{"default":"DESC","type":"string"}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/NetworkPerformanceResponseDto"}}}}]}}}}},"summary":"","tags":["Social Network Level"]}},"/v1/reporting/network/return-on-investment":{"get":{"description":"Get social networks return on investment details.","operationId":"findReturnOfInvestments","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/NetworkReturnOnInvestmentResponseDto"}},"meta":{"nullable":true,"example":null}}}]}}}}},"summary":"","tags":["Social Network Level"]}},"/v1/reporting/influencer/performance":{"get":{"description":"Get influencer performance details.","operationId":"getInfluencerPerformance","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}},{"name":"pageSize","required":false,"in":"query","description":"Number of items per page","schema":{"default":50,"type":"number"}},{"name":"pageNumber","required":false,"in":"query","description":"The page you would like to get data for","schema":{"default":1,"type":"number"}},{"name":"sortProperty","required":false,"in":"query","description":"sortProperty must be one of the following values: engagements, impressions, engagementRate, estimatedValueGenerated, instagramReach, instagramSaved, instagramShares, instagramViews, instagramTotalInteractions, estimatedContentCost, cpm, cpe, estimatedRoi, postsCount, trackingLinksClicks, trackingLinksConversions, trackingLinksConversionValue, affiliateLinksClicks, affiliateLinksConversions, affiliateLinksConversionRate, affiliateLinksSales, affiliateLinksComissionEarned, affiliateLinksRoi, paidCost","schema":{"type":"string"}},{"name":"sortDirection","required":false,"in":"query","description":"ASC or DESC","schema":{"default":"DESC","type":"string"}},{"name":"metrics","required":false,"in":"query","description":"A list of metrics to get the data for. Empty or undefined, to get all the metrics","schema":{"example":["engagements","impressions"],"type":"array","items":{"type":"string","enum":["engagements","impressions","engagementRate","estimatedValueGenerated","estimatedRoi","cpe","cpm","estimatedContentCost","paidCost","postsCount","trackingLinksClicks","trackingLinksConversions","trackingLinksConversionValue","affiliateLinksClicks","affiliateLinksConversions","affiliateLinksConversionRate","affiliateLinksSales","affiliateLinksComissionEarned","affiliateLinksRoi"]}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/InfluencerPerformanceResponseDto"}}}}]}}}}},"summary":"","tags":["Influencer Level"]}},"/v1/reporting/post/performance":{"get":{"description":"Get post performance details.","operationId":"getPostPerformance","parameters":[{"name":"startDate","required":true,"in":"query","description":"Start date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"endDate","required":true,"in":"query","description":"End date for the report, YYYY-MM-dd format","schema":{"format":"date-time","type":"string"}},{"name":"instanceIds","required":false,"in":"query","description":"A list of instance ids. If not provided, all instances associated with the API credentials will be considered.","schema":{"type":"array","items":{"type":"string"}}},{"name":"campaignIds","required":false,"in":"query","description":"A list of campaign ids (max 50 items)","schema":{"type":"array","items":{"type":"number"}}},{"name":"reportingGroupIds","required":false,"in":"query","description":"A list of reporting group ids","schema":{"type":"array","items":{"type":"string"}}},{"name":"pageSize","required":false,"in":"query","description":"Number of items per page","schema":{"default":50,"type":"number"}},{"name":"pageNumber","required":false,"in":"query","description":"The page you would like to get data for","schema":{"default":1,"type":"number"}},{"name":"sortProperty","required":false,"in":"query","description":"sortProperty must be one of the following values: engagements, impressions, engagementRate, estimatedValueGenerated, cpm, cpe, postDate","schema":{"type":"string"}},{"name":"sortDirection","required":false,"in":"query","description":"ASC or DESC","schema":{"default":"DESC","type":"string"}},{"name":"metrics","required":false,"in":"query","description":"A list of metrics to get the data for. Empty or undefined, to get all the metrics","schema":{"example":["engagements","impressions"],"type":"array","items":{"type":"string","enum":["engagements","impressions","engagementRate","estimatedValueGenerated","cpe","cpm"]}}}],"responses":{"200":{"description":"","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ReportingApiResponseDto"},{"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PostPerformanceResponseDto"}}}}]}}}}},"summary":"","tags":["Post Level"]}}},"info":{"title":"Later Influence™ API","description":"\n# Description\nThe Reporting API enables deep analysis and reporting of marketing campaigns, social media performance, and influencer effectiveness.\nIt provides comprehensive performance insights at multiple levels:\n- Instance Level: Get instance details, overall performance, and performance over time\n- Campaign Level: Retrieve detailed campaign performance metrics\n- Social Network Level: Analyze performance across different social networks and calculate return on investment\n- Influencer Level: Evaluate individual influencer performance\n- Post Level: Access granular performance data for individual posts\n\n# Authentication\nIn order to use the Reporting API, OAuth2 authentication is required. The API uses the client credentials flow for authentication. To obtain an access token:\n\n1. Request the client credentials (client ID and client secret) from the support team.\n2. Make a POST request to the token endpoint: `https://api.mavrck.co/oauth/token`, including your client credentials in the request body.\n\nCurl Example: \n```\ncurl --request POST \\\n  --url 'https://api.mavrck.co/oauth/token' \\\n  --header 'Content-Type: application/json' \\\n  --header 'accept: application/json' \\\n  --data '{\n    \"clientId\": \"<client_id>\",\n    \"clientSecret\": \"<client_secret>\"\n  }'\n```\n\n3. Include the obtained access token in the Authorization header of your API requests:\n\nCurl Example: \n```\ncurl --request GET \\\n  --url 'https://api.mavrck.co/v1/reporting/instance/details' \\\n  --header 'Content-Type: application/json' \\\n  --header 'accept: application/json' \\\n  --header 'Authorization: Bearer **<your_access_token>**' \\\n```\n\nFor security reasons, access tokens have a limited lifespan of 12 hours. You should implement a mechanism to refresh the token when it expires.\n\n# Data Availability\n- Most endpoints return analytics that are current up to the previous day, as several social media platforms apply a 24-hour reporting delay.\n- Data access is limited to the specific account or instances associated with the provided API credentials.\n- Analytics are recorded on a daily basis and appear only when they fall within the selected date-range filters. For example, if a post was published a week ago but receives its first interaction today, that interaction will only be included when today’s date is part of the chosen range.\n\n# Base Filters\nAll endpoints support the following filters:\n- `startDate` (ISO 8601 format, e.g. 2024-01-01)\n- `endDate` (ISO 8601 format, e.g. 2024-01-01). There is a limit of up to 2 years for the selected date range.\n- `instanceIds` array of instance ids. If not provided, all instances associated with the API credentials will be considered.\n- `campaignIds` array of campaign ids, if no campaign ids are provided, all campaigns for the instance will be used\n- `reportingGroupIds` array of reporting group ids, if no reporting group ids are provided, all reporting groups for the instance will be used\n\n# Pagination\n- The pagination is available for endpoints returning large datasets.\n- Use `pageSize` and `pageNumber` query parameters to control the results. For the `pageSize` parameter, the default is 50 and the maximum is 100.\n\n# Versioning\n- API versioning supported through URI path\n\n# Changelog\n\n---\n\n## 2025-11-25 Introduce Multi-instance support\n### Added\n- `GET /instances` API - Retrieve the list of instances accessible by the provided API credentials.\n- `GET /instances/details` API - Get detailed information about the instances associated with the provided API credentials such as `influencersCount`, `campaignsCount`, and other relevant metrics. It is similar to the existing `GET /instance/details` endpoint but supports multiple instances.\n\n### Changed\n- All endpoints now support an `instanceIds` query parameter, allowing you to filter results by specific instance IDs when your credentials have access to multiple instances.\n- `GET /campaigns/performance` response includes a new string field `instanceId`.\n- `GET /post/performance` response includes a new string field `instanceId`.\n\n","version":"1.2.1","contact":{"name":"Developer","url":"https://help-influence.later.com/hc/en-us","email":"urvash.chheda@later.com"},"termsOfService":"https://later.com/terms/"},"tags":[],"servers":[{"url":"https://api.mavrck.co"}],"components":{"securitySchemes":{"JWT":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"JWT obtained from the OAuth2 token endpoint"}},"schemas":{"TokenRequestDto":{"type":"object","properties":{"clientId":{"type":"string","description":"Client ID required to get the JWT token used for authentication","example":"client_id_123"},"clientSecret":{"type":"string","description":"Client Secret required to get the JWT token used for authentication","example":"client_secret_456"}},"required":["clientId","clientSecret"]},"TokenResponseDto":{"type":"object","properties":{"jwt":{"type":"string","description":"The JWT token using which the reporting APIs need to be authenticated","example":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."}},"required":["jwt"]},"ReportingApiResponseDto":{"type":"object","properties":{"data":{"type":"object","additionalProperties":false},"meta":{"type":"object","description":"Metadata containing page information","nullable":true,"properties":{"page":{"type":"number","example":1},"totalPages":{"type":"number","example":10}}}},"required":["data","meta"]},"InstancesResponseDto":{"type":"object","properties":{"instanceIds":{"description":"A list of instance ids the API credentials have access to","example":["instance_123","instance_456"],"type":"array","items":{"type":"string"}}},"required":["instanceIds"]},"InstanceCampaignDto":{"type":"object","properties":{"id":{"type":"number","description":"Unique identifier for the campaign","example":1},"title":{"type":"string","description":"Title of the campaign","nullable":true,"example":"Summer Sale Campaign"},"description":{"type":"string","description":"Description of the campaign","nullable":true,"example":"This campaign is focused on summer sales."},"status":{"type":"string","description":"Status of the campaign","nullable":true,"example":"active"},"startDate":{"type":"string","description":"Start date of the campaign","format":"date-time","nullable":true,"example":"2023-10-01T00:00:00Z"}},"required":["id","title","description","status","startDate"]},"InstanceDetailsResponseDto":{"type":"object","properties":{"id":{"type":"string","description":"Unique identifier for the instance","example":"instance_123"},"campaignsCount":{"type":"number","description":"Number of campaigns associated with the instance","example":5},"influencersCount":{"type":"number","description":"Number of influencers associated with the instance","example":10},"campaigns":{"description":"List of campaigns associated with the instance","example":[{"id":49761,"title":"demo campaign 1","description":"","status":"LIVE","startDate":"2023-06-06T06:52:00.000Z"},{"id":49762,"title":"demo campaign 2","description":null,"status":"LIVE","startDate":"2023-06-07T06:29:00.000Z"}],"type":"array","items":{"$ref":"#/components/schemas/InstanceCampaignDto"}}},"required":["id","campaignsCount","influencersCount","campaigns"]},"InstancePerformanceResponseDto":{"type":"object","properties":{"engagements":{"type":"number","example":1000,"description":"Total number of engagements","nullable":true},"impressions":{"type":"number","example":10000,"description":"Total number of impressions","nullable":true},"engagementRate":{"type":"number","example":0.1,"description":"Engagement rate as a decimal","nullable":true},"postsCount":{"type":"number","example":50,"description":"Total number of posts","nullable":true},"valueGenerated":{"type":"number","example":5000,"description":"Total value generated","nullable":true},"returnOnInvestment":{"type":"number","example":2.5,"description":"Return on investment as a ratio","nullable":true},"estimatedContentCost":{"type":"number","example":2000,"description":"Is calculated based on how many posts received metrics in the selected time range vs the amount of money paid to the author(influencer)","nullable":true},"campaignsCost":{"type":"number","example":3000,"description":"Is calculated based on the paid amount to influencers participating in the selected campaigns","nullable":true},"conversionValue":{"type":"number","example":7500,"description":"Total tracking links conversion value","nullable":true}},"required":["engagements","impressions","engagementRate","postsCount","valueGenerated","returnOnInvestment","estimatedContentCost","campaignsCost","conversionValue"]},"ReportingApiGranularResponseDto":{"type":"object","properties":{"data":{"type":"object","description":"A data object containing a generic metrics object | array and a date object","additionalProperties":true},"meta":{"type":"object","description":"Metadata containing page information","properties":{"page":{"type":"number","example":1},"totalPages":{"type":"number","example":10}}}},"required":["data","meta"]},"InstancePerformanceOverTimeMetricsDto":{"type":"object","properties":{"likes":{"type":"number","example":100,"description":"Number of likes","nullable":true},"comments":{"type":"number","example":50,"description":"Number of comments","nullable":true},"shares":{"type":"number","example":25,"description":"Number of shares","nullable":true},"clicks":{"type":"number","example":200,"description":"Number of clicks","nullable":true},"engagements":{"type":"number","example":375,"description":"Total number of engagements","nullable":true},"impressions":{"type":"number","example":1000,"description":"Number of impressions","nullable":true},"valueGenerated":{"type":"number","example":500.5,"description":"Value generated","nullable":true},"engagementRate":{"type":"number","example":0.375,"description":"Engagement rate","nullable":true},"cpe":{"type":"number","example":1.33,"description":"Cost per engagement","nullable":true},"cpm":{"type":"number","example":5,"description":"Cost per mille (thousand impressions)","nullable":true}},"required":["likes","comments","shares","clicks","engagements","impressions","valueGenerated","engagementRate","cpe","cpm"]},"PerformanceOverTimeDateDto":{"type":"object","properties":{"year":{"type":"number","description":"Year","example":2023},"quarter":{"type":"number","description":"Quarter","example":4},"month":{"type":"number","description":"Month","example":10},"week":{"type":"number","description":"Week","example":42},"day":{"type":"number","description":"Day","example":15},"fullDate":{"type":"string","description":"ISO 8601 date format (YYYY-MM-DD)","example":"2023-10-15"}},"required":["year"]},"CampaignPerformanceResponseDto":{"type":"object","properties":{"campaignId":{"type":"number","example":1,"description":"Unique identifier for the campaign"},"campaignTitle":{"type":"string","example":"Campaign Title","description":"Title of the campaign","nullable":true},"instanceId":{"type":"string","example":"instance_123","description":"Identifier of the instance"},"description":{"type":"string","example":"Description of the campaign","description":"Detailed description of the campaign","nullable":true},"postsCount":{"type":"number","example":10,"description":"Total number of posts in the campaign","nullable":true},"influencersCount":{"type":"number","example":5,"description":"Number of influencers participating in the campaign","nullable":true},"reach":{"type":"number","example":1000,"description":"Total reach of the campaign. Usually it represents the number of followers/subscribers/audience reached, but for Pinterest it is the number of Monthly Viewers","nullable":true},"engagements":{"type":"number","example":100,"description":"Total number of engagements for the campaign","nullable":true},"impressions":{"type":"number","example":500,"description":"Total number of impressions for the campaign","nullable":true},"clicks":{"type":"number","example":50,"description":"Total number of clicks for the campaign","nullable":true},"engagementRate":{"type":"number","example":0.1,"description":"Engagement rate of the campaign","nullable":true},"uniqueNetworks":{"type":"string","example":"Facebook, Instagram","description":"Comma-separated list of unique social networks used in the campaign","nullable":true},"cpe":{"type":"number","example":0.05,"description":"Cost per engagement for the campaign","nullable":true},"cpm":{"type":"number","example":10,"description":"Cost per thousand impressions for the campaign","nullable":true},"firstPostDate":{"format":"date-time","type":"string","example":"2025-11-26T14:12:56.038Z","description":"Date of the first post in the campaign","nullable":true},"lastPostDate":{"format":"date-time","type":"string","example":"2025-11-26T14:12:56.038Z","description":"Date of the last post in the campaign","nullable":true},"impressionsPerPost":{"type":"number","example":50,"description":"Average number of impressions per post in the campaign","nullable":true},"estimatedContentCost":{"type":"number","example":1000,"description":"Is calculated based on how many posts within the campaign received metrics in the selected time range vs the amount of money paid to the author(influencer)","nullable":true},"estimatedValueGenerated":{"type":"number","example":2000,"description":"Estimated value generated by the campaign","nullable":true},"estimatedRoi":{"type":"number","example":2,"description":"Estimated return on investment for the campaign","nullable":true},"trackingLinksClicks":{"type":"number","example":100,"description":"Total number of clicks on tracking links","nullable":true},"trackingLinksConversions":{"type":"number","example":10,"description":"Total number of conversions from tracking links","nullable":true},"trackingLinksConversionValue":{"type":"number","example":500,"description":"Total conversion value from tracking links","nullable":true},"affiliateLinksClicks":{"type":"number","example":50,"description":"Total number of clicks on affiliate links","nullable":true},"affiliateLinksConversions":{"type":"number","example":5,"description":"Total number of conversions from affiliate links","nullable":true},"affiliateLinksConversionRate":{"type":"number","example":0.1,"description":"Conversion rate for affiliate links","nullable":true},"affiliateLinksSales":{"type":"number","example":1000,"description":"Total sales value from affiliate links","nullable":true},"affiliateLinksComissionEarned":{"type":"number","example":100,"description":"Total commission earned from affiliate links","nullable":true},"affiliateLinksRoi":{"type":"number","example":2,"description":"Return on investment for affiliate links","nullable":true}},"required":["campaignId","campaignTitle","instanceId","description","postsCount","influencersCount","reach","engagements","impressions","clicks","engagementRate","uniqueNetworks","cpe","cpm","firstPostDate","lastPostDate","impressionsPerPost","estimatedContentCost","estimatedValueGenerated","estimatedRoi","trackingLinksClicks","trackingLinksConversions","trackingLinksConversionValue","affiliateLinksClicks","affiliateLinksConversions","affiliateLinksConversionRate","affiliateLinksSales","affiliateLinksComissionEarned","affiliateLinksRoi"]},"NetworkPerformanceResponseDto":{"type":"object","properties":{"socialNetwork":{"type":"string","example":"Instagram","enum":["blog","facebook","facebook_live","facebook_group","facebook_reel","image","instagram","instagram_reel","instagram_story","linkedin","musical_ly","pinterest","snapchat_story","tiktok","twitch_stream","twitter","youtube_video","youtube_shorts","video"],"description":"Name of the social network"},"postsCount":{"type":"number","example":100,"description":"Total number of posts","nullable":true},"impressions":{"type":"number","example":10000,"description":"Total number of impressions","nullable":true},"impressionsPerPosts":{"type":"number","example":100,"description":" Average impressions per post","nullable":true},"engagements":{"type":"number","example":500,"description":"Total number of engagements","nullable":true},"engagementsPerPosts":{"type":"number","example":5,"description":"Average engagements per post","nullable":true},"engagementRate":{"type":"number","example":0.05,"description":"Engagement rate as a decimal","nullable":true}},"required":["socialNetwork","postsCount","impressions","impressionsPerPosts","engagements","engagementsPerPosts","engagementRate"]},"NetworkReturnOnInvestmentResponseDto":{"type":"object","properties":{"socialNetwork":{"type":"string","enum":["blog","facebook","facebook_live","facebook_group","facebook_reel","image","instagram","instagram_reel","instagram_story","linkedin","musical_ly","pinterest","snapchat_story","tiktok","twitch_stream","twitter","youtube_video","youtube_shorts","video"],"description":"Name of the social network","example":"instagram"},"valueOfShares":{"type":"number","example":1000,"description":"Value generated from shares","nullable":true},"valueOfImpressions":{"type":"number","example":1500,"description":"Value generated from impressions","nullable":true},"valueOfComments":{"type":"number","example":800,"description":"Value generated from comments","nullable":true},"valueOfLikes":{"type":"number","example":700,"description":"Value generated from likes","nullable":true},"valueGenerated":{"type":"number","example":5000,"description":"Total value generated","nullable":true},"estimatedContentCost":{"type":"number","example":2000,"description":"Is calculated based on how many posts received metrics in the selected time range for a specific network vs the amount of money paid to the author(influencer)","nullable":true},"returnOnInvestment":{"type":"number","example":2.5,"description":"Return on investment as a ratio","nullable":true}},"required":["valueOfShares","valueOfImpressions","valueOfComments","valueOfLikes","valueGenerated","estimatedContentCost","returnOnInvestment"]},"CreatorProfileDto":{"type":"object","properties":{"handleName":{"type":"string","description":"Handle name of the creator","example":"johndoe"},"network":{"type":"string","description":"Social network of the creator","example":"Instagram"},"fullName":{"type":"string","description":"Full name of the creator","nullable":true,"example":"John Doe"},"profileImage":{"type":"string","description":"Profile image URL","nullable":true,"example":"https://example.com/profile.jpg"},"profileLink":{"type":"string","description":"Profile link","nullable":true,"example":"https://instagram.com/johndoe"}},"required":["handleName","network"]},"CreatorDto":{"type":"object","properties":{"globalUserId":{"type":"number","description":"Global user ID of the creator","example":12345},"profilePictureUrl":{"type":"string","description":"Profile picture URL","nullable":true,"example":"https://example.com/profile.jpg"},"fullName":{"type":"string","description":"Full name of the creator","nullable":true,"example":"John Doe"},"profiles":{"description":"Creator profiles","type":"array","items":{"$ref":"#/components/schemas/CreatorProfileDto"}}},"required":["globalUserId","profiles"]},"InfluencerPerformanceResponseDto":{"type":"object","properties":{"creator":{"description":"Creator information","allOf":[{"$ref":"#/components/schemas/CreatorDto"}]},"creatorGlobalUserId":{"type":"number","description":"Global user ID of the creator","example":12345},"engagements":{"type":"number","description":"Number of engagements","nullable":true,"example":1000},"impressions":{"type":"number","description":"Number of impressions","nullable":true,"example":10000},"engagementRate":{"type":"number","description":"Engagement rate","nullable":true,"example":0.1},"estimatedValueGenerated":{"type":"number","description":"Estimated value generated","nullable":true,"example":5000},"paidCost":{"type":"number","description":"Paid cost","nullable":true,"example":2000},"estimatedRoi":{"type":"number","description":"Estimated ROI","nullable":true,"example":2.5},"cpe":{"type":"number","description":"Cost per engagement","nullable":true,"example":0.5},"cpm":{"type":"number","description":"Cost per mille","nullable":true,"example":5},"estimatedContentCost":{"type":"number","description":"Estimated content cost","nullable":true,"example":1000},"postsCount":{"type":"number","description":"Number of posts","nullable":true,"example":10},"clicks":{"type":"number","description":"Number of clicks","nullable":true,"example":500},"conversionValue":{"type":"number","description":"Conversion value","nullable":true,"example":2000},"trackingLinksClicks":{"type":"number","description":"Number of tracking link clicks","nullable":true,"example":300},"trackingLinksConversions":{"type":"number","description":"Number of tracking link conversions","nullable":true,"example":50},"trackingLinksConversionValue":{"type":"number","description":"Tracking links conversion value","nullable":true,"example":1500},"affiliateLinksClicks":{"type":"number","description":"Number of affiliate link clicks","nullable":true,"example":200},"affiliateLinksConversions":{"type":"number","description":"Number of affiliate link conversions","nullable":true,"example":30},"affiliateLinksConversionRate":{"type":"number","description":"Affiliate links conversion rate","nullable":true,"example":0.15},"affiliateLinksSales":{"type":"number","description":"Affiliate links sales","nullable":true,"example":3000},"affiliateLinksComissionEarned":{"type":"number","description":"Affiliate links commission earned","nullable":true,"example":300},"affiliateLinksRoi":{"type":"number","description":"Affiliate links ROI","nullable":true,"example":3}},"required":["creator","creatorGlobalUserId"]},"PostPerformanceResponseDto":{"type":"object","properties":{"activationId":{"type":"number","description":"Activation ID","example":1234},"creatorId":{"type":"number","description":"Creator ID","example":5678},"instanceId":{"type":"string","description":"Instance ID","example":"instance_123"},"creatorGlobalUserId":{"type":"number","description":"Creator Global User ID","example":91011},"actionGroupId":{"type":"number","description":"Action Group ID","example":9012},"postDate":{"type":"string","description":"Post date","example":"2023-05-01T12:00:00Z"},"engagements":{"type":"number","description":"Number of engagements","example":1000,"nullable":true},"impressions":{"type":"number","description":"Number of impressions","example":10000,"nullable":true},"engagementRate":{"type":"number","description":"Engagement rate","example":0.1,"nullable":true},"estimatedValueGenerated":{"type":"number","description":"Estimated value generated","example":500.5,"nullable":true},"cpe":{"type":"number","description":"Cost per engagement","example":0.05,"nullable":true},"cpm":{"type":"number","description":"Cost per mille (thousand impressions)","example":2.5,"nullable":true},"socialNetwork":{"type":"string","description":"Name of the social network","example":"instagram"},"contentUrl":{"type":"string","description":"URL of the content","example":"https://www.instagram.com/p/ABC123/"},"contentImageUrl":{"type":"string","description":"URL of the content image","example":"https://example.com/image.jpg"},"creatorProfile":{"description":"Creator profile","nullable":true,"example":{"handleName":"influencer123","network":"Instagram","fullName":"John Doe","profileLink":"https://instagram.com/johndoe","profileImage":"https://example.com/profile.jpg"},"allOf":[{"$ref":"#/components/schemas/CreatorProfileDto"}]}},"required":["activationId","creatorId","instanceId","creatorGlobalUserId","actionGroupId","postDate","socialNetwork","contentUrl","contentImageUrl"]}}},"security":[{"JWT":[]}]}