{"abstract":[{"text":"Generates a token.","type":"text"}],"hierarchy":{"paths":[["doc:\/\/com.apple.documentation\/documentation\/technologies","doc:\/\/com.apple.AdServices\/documentation\/AdServices","doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttribution"]]},"identifier":{"interfaceLanguage":"swift","url":"doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttribution\/attributionToken()"},"kind":"symbol","legalNotices":{"copyright":"Copyright &copy; 2026 Apple Inc. All rights reserved.","privacyPolicy":"https:\/\/www.apple.com\/privacy\/privacy-policy","termsOfUse":"https:\/\/www.apple.com\/legal\/internet-services\/terms\/site.html"},"metadata":{"availableLanguages":["de-DE","en-US","es-419","fr-FR","it-IT","ja-JP","ko-KR","pt-BR","zh-CN"],"externalID":"c:objc(cs)AAAttribution(cm)attributionTokenWithError:","fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"attributionToken"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","preciseIdentifier":"s:SS","text":"String"}],"modules":[{"name":"AdServices"}],"navigatorTitle":[{"kind":"text","text":"+ "},{"kind":"identifier","text":"attributionTokenWithError:"}],"platforms":[{"beta":false,"deprecated":false,"introducedAt":"14.3","name":"iOS","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"14.3","name":"iPadOS","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"14.3","name":"Mac Catalyst","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"11.1","name":"macOS","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"1.0","name":"visionOS","unavailable":false}],"role":"symbol","roleHeading":"Type Method","symbolKind":"method","title":"attributionToken()"},"primaryContentSections":[{"declarations":[{"languages":["swift"],"platforms":["iOS","iPadOS","Mac Catalyst","macOS","visionOS"],"tokens":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"attributionToken"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Swift\/String","kind":"typeIdentifier","preciseIdentifier":"s:SS","text":"String"}]}],"kind":"declarations"},{"content":[{"anchor":"discussion","level":2,"text":"Discussion","type":"heading"},{"inlineContent":[{"text":"The token that the framework returns is a Base64 encoded string and has a 24-hour TTL. You can provide the token to a Mobile Measurement Provider (MMP), or app developers can use it to make a ","type":"text"},{"code":"POST","type":"codeVoice"},{"text":" API call to fetch attribution records within the 24-hour TTL window. Use a single token in the request body and use a content-type of ","type":"text"},{"code":"text\/plain","type":"codeVoice"},{"text":" in the header, as the following example shows:","type":"text"}],"type":"paragraph"},{"code":["POST https:\/\/api-adservices.apple.com\/api\/v1\/","--header 'Content-Type: text\/plain' \\","--data-raw","","G9i5hC8lQJeGOfmS+MFycll\/025oJEjtpZ+rs4AUkDEJh52fT8RrjwIR\/h+2JOpXz4MRdmtcemL8WTTHfNN52tjqjbWupke40AAAAVADAAAAvQAAAIAgQF1+XF4Tl2IZ7Bw\/M6ufUHt+UcIhuBeJT8YenB2v36bnZKEjvq\/IH8rqXkRELTHdyiqOYtpy837+UjF\/NjE6t1\/l7sIn71b0t3FEXJd8QOtl3Bi6iQyJgGeN8w8X0MK1PDqz9nLJtRD\/wl+p112qR2YrMDyyKnwNrbfRhnGB9AAAAB7wAXlwNHelWf5RT2bzSJcGflqELMCGoDEHIl7jF6kAAACfAb9ylY8ffdbTlyJODQYQ\/6V9qbaBAAAAhgUBW39MQI1A0SZgNmZFz4KPaF94BxBzd4rDkjr\/eSeuaXWCmEW3ZhBzE\/MOM17hAPBVlDhTPcZ\/2ybr3WYIkfb+AAg\/7jxGpDXgTtco3fzTytnZpEaI5SenXHALIexQAUTBsfBW2HCMQuTRo+7anoWkf69656ZAWcSc3DEQ1CAkUSKO9X7iAAABBEQQBQA="],"syntax":"other","type":"codeListing"},{"content":[{"inlineContent":[{"text":"A 404 response can occur if you make an API call too quickly after receiving a valid token. A best practice is to initiate retries at intervals of 5 seconds, with a maximum of three attempts.","type":"text"}],"type":"paragraph"}],"name":"Important","style":"important","type":"aside"},{"inlineContent":[{"text":"For details about error codes, see ","type":"text"},{"identifier":"doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttributionError","isActive":true,"type":"reference"},{"text":".","type":"text"}],"type":"paragraph"},{"anchor":"Response-codes","level":2,"text":"Response codes","type":"heading"},{"header":"row","rows":[[[{"inlineContent":[{"inlineContent":[{"text":"Response","type":"text"}],"type":"strong"}],"type":"paragraph"}],[{"inlineContent":[{"inlineContent":[{"text":"Description","type":"text"}],"type":"strong"}],"type":"paragraph"}]],[[{"inlineContent":[{"text":"200","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Success. If the API finds a matching attribution record, the payload returns ","type":"text"},{"code":"attribution=true","type":"codeVoice"},{"text":". ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"If the API cannot find a matching attribution record, or if the ad group uses age or gender settings, the payload returns ","type":"text"},{"code":"attribution=false","type":"codeVoice"},{"text":". In this case, the ","type":"text"},{"code":"200","type":"codeVoice"},{"text":" ","type":"text"},{"code":"OK","type":"codeVoice"},{"text":" response is acknowledgment of the receipt of the data request.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"text":"400","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The token is invalid.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"text":"404","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Not found. The API is unable to retrieve the requested attribution record.  ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Tokens have a TTL of 24 hours. If the ","type":"text"},{"code":"POST","type":"codeVoice"},{"text":" API call exceeds 24 hours, a ","type":"text"},{"code":"404","type":"codeVoice"},{"text":" response returns. If your token is valid, a best practice is to initiate retries at intervals of 5 seconds with a maximum of three attempts.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"text":"500","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The Apple Ads server is temporarily down or unreachable. The request may be valid, but you need to retry it later.","type":"text"}],"type":"paragraph"}]]],"type":"table"},{"anchor":"Attribution-payloads","level":2,"text":"Attribution payloads","type":"heading"},{"inlineContent":[{"text":"The attribution record is a data dictionary with key-value pairs that correspond to your Apple Ads campaigns and app downloads from devices running iOS 14 and later. Run reports to review detailed campaign metadata in the ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API","isActive":true,"type":"reference"},{"text":" or ","type":"text"},{"identifier":"https:\/\/ads.apple.com\/advanced\/","isActive":true,"type":"reference"},{"text":".","type":"text"}],"type":"paragraph"},{"content":[{"inlineContent":[{"text":"If you receive test data in your payload responses, check to make sure your app isn’t in developer mode. AdServices will return a test payload when developer mode is on:","type":"text"}],"type":"paragraph"}],"name":"Note","style":"note","type":"aside"},{"code":["{","  \"attribution\": true,","  \"orgId\": 1234567890,","  \"campaignId\": 1234567890,","  \"conversionType\": \"Download\",","  \"clickDate\": \"2020-04-08T17:17Z\",","  \"claimType\": \"Click\",","  \"adGroupId\": 1234567890,","  \"countryOrRegion\": \"US\",","  \"keywordId\": 123222,","  \"adId\": 542317136,","  \"supplyPlacement\": \"APPSTORE_SEARCH_RESULTS\"","}"],"syntax":"json","type":"codeListing"},{"anchor":"Tap-through-payload-example","level":3,"text":"Tap-through payload example","type":"heading"},{"inlineContent":[{"text":"A payload for tap-through attribution resembles the following:","type":"text"}],"type":"paragraph"},{"code":["{","  \"attribution\": true,","  \"orgId\": 40669820,","  \"campaignId\": 542370539,","  \"conversionType\": \"Download\",","  \"clickDate\": \"2024-10-08T17:17Z\",","  \"claimType\": \"Click\",","  \"adGroupId\": 542317095,","  \"countryOrRegion\": \"US\",","  \"keywordId\": 87675432,","  \"adId\": 542317136,","  \"supplyPlacement\": \"APPSTORE_SEARCH_RESULTS\"","}"],"syntax":"json","type":"codeListing"},{"anchor":"View-through-payload-example","level":3,"text":"View-through payload example","type":"heading"},{"inlineContent":[{"text":"A payload for view-through attribution resembles the following:","type":"text"}],"type":"paragraph"},{"code":["{","  \"attribution\": true,","  \"orgId\": 40669820,","  \"campaignId\": 542370539,","  \"conversionType\": \"Download\",","  \"impressionDate\": \"2024-10-08T17:17Z\",","  \"claimType\": \"Impression\",","  \"adGroupId\": 542317095,","  \"countryOrRegion\": \"US\",","  \"keywordId\": 87675432,","  \"adId\": 542317136,","  \"supplyPlacement\": \"APPSTORE_SEARCH_RESULTS\"","}"],"syntax":"json","type":"codeListing"},{"anchor":"Pre-order-payload-example","level":3,"text":"Pre-order payload example","type":"heading"},{"inlineContent":[{"text":"A payload for pre-order attribution on tap-throughs resembles the following:","type":"text"}],"type":"paragraph"},{"code":["{","  \"attribution\": true,","  \"orgId\": 40669820,","  \"campaignId\": 542370539,","  \"conversionType\": \"PreOrder\",","  \"clickDate\": \"2020-04-08T17:17Z\",","  \"claimType\": \"Click\",","  \"adGroupId\": 542317095,","  \"countryOrRegion\": \"US\",","  \"keywordId\": 87675432,","  \"adId\": 542317136,","  \"supplyPlacement\": \"APPSTORE_SEARCH_RESULTS\"","}"],"syntax":"json","type":"codeListing"},{"inlineContent":[{"text":"A payload for pre-order attribution on view-throughs resembles the following:","type":"text"}],"type":"paragraph"},{"code":["{","  \"attribution\": true,","  \"orgId\": 40669820,","  \"campaignId\": 542370539,","  \"conversionType\": \"PreOrder\",","  \"impressionDate\": \"2020-04-08T17:17Z\",","  \"claimType\": \"Impression\",","  \"adGroupId\": 542317095,","  \"countryOrRegion\": \"US\",","  \"keywordId\": 87675432,","  \"adId\": 542317136,","  \"supplyPlacement\": \"APPSTORE_SEARCH_RESULTS\"","}"],"syntax":"json","type":"codeListing"},{"anchor":"Attribution-payload-descriptions","level":2,"text":"Attribution payload descriptions","type":"heading"},{"header":"row","rows":[[[{"inlineContent":[{"inlineContent":[{"text":"Field","type":"text"}],"type":"strong"}],"type":"paragraph"}],[{"inlineContent":[{"inlineContent":[{"text":"Data type","type":"text"}],"type":"strong"}],"type":"paragraph"}],[{"inlineContent":[{"inlineContent":[{"text":"Description","type":"text"}],"type":"strong"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"adGroupId","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"long","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The identifier for the ad group. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Use ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-ad-group-reports","isActive":true,"type":"reference"},{"text":" to correlate your attribution response by ","type":"text"},{"code":"adGroupId","type":"codeVoice"},{"text":" and its corresponding campaign in the Apple Ads Platform API.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"adId","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"long","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The identifier representing the assignment relationship between an ","type":"text"},{"code":"ad","type":"codeVoice"},{"text":" object and an ad group. This ID applies to devices running iOS 15.2 and later. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Use ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-ad-reports","isActive":true,"type":"reference"},{"text":" to correlate your attribution response by ","type":"text"},{"code":"adId","type":"codeVoice"},{"text":" in the Apple Ads Platform API.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"attribution","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"boolean","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The attribution value. A value of ","type":"text"},{"code":"true","type":"codeVoice"},{"text":" returns if a user clicks an Apple Ads impression up to 30 days before your app download or views it within 24 hours. If the API can’t find a matching attribution record, the attribution value is ","type":"text"},{"code":"false","type":"codeVoice"},{"text":". ","type":"text"},{"identifier":"spacer","type":"image"},{"text":" Note: campaigns with age and gender targeting criteria return a value of ","type":"text"},{"code":"false","type":"codeVoice"},{"text":". See ","type":"text"},{"code":"claimType","type":"codeVoice"},{"text":" for more details.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"campaignId","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"long","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The unique identifier for the campaign. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Use ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-campaign-reports","isActive":true,"type":"reference"},{"text":" in the Apple Ads Platform API to correlate your attribution response by ","type":"text"},{"code":"campaignId","type":"codeVoice"},{"text":".","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"claimType","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"string","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"For view-through attribution, ","type":"text"},{"code":"claimType","type":"codeVoice"},{"text":" will have a value of ","type":"text"},{"code":"Impression","type":"codeVoice"},{"text":" to indicate users who viewed an ad in a corresponding Apple Ads campaign but didn’t tap on it, within 24 hours of an ad view. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"For tap-through attribution, ","type":"text"},{"code":"claimType","type":"codeVoice"},{"text":" will have a value of ","type":"text"},{"code":"Click","type":"codeVoice"},{"text":", specifying that the user tapped on an ad. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Note: the tap-through attribution window is 30 days and tap-through attribution is prioritized over view-through attribution.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"clickDate","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"date\/time string","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The date and time when the user clicks an ad in a corresponding campaign. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"This field only appears in the attribution response payload.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"conversionType","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"string","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The type of conversion. Values are ","type":"text"},{"code":"Download","type":"codeVoice"},{"text":", ","type":"text"},{"code":"Redownload","type":"codeVoice"},{"text":" or ","type":"text"},{"code":"PreOrder","type":"codeVoice"},{"text":". The ","type":"text"},{"code":"PreOrder","type":"codeVoice"},{"text":" value attributes both clicks and views. If a pre-order was placed within 30 days from the click or 1 day from the view, the lookback window for click-throughs is 90 days. The lookback window for view-throughs is 61 days. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Conversion types appear in your ","type":"text"},{"identifier":"https:\/\/developer.apple.com\/documentation\/apple-ads-platform-api\/appscampaignmetrics","isActive":true,"type":"reference"},{"text":" in the Apple Ads Platform API.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"countryOrRegion","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"string","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The country or region for the campaign. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Refer to the ","type":"text"},{"code":"groupBy","type":"codeVoice"},{"text":" section of the ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/AppsReportingRequest","isActive":true,"type":"reference"},{"text":" in the Apple Ads Platform API for more details.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"impressionDate","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"UTC string","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Represents the date and time when an ad view occurs in a corresponding Apple Ads campaign. The ","type":"text"},{"code":"impressionDate","type":"codeVoice"},{"text":" attribute appears in the view-through attribution response payload.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"keywordId","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"long","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The identifier for the keyword. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Use ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-keyword-reports","isActive":true,"type":"reference"},{"text":" in the Apple Ads Platform API to correlate your attribution response by ","type":"text"},{"code":"keywordId","type":"codeVoice"},{"text":". ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Note, when you enable search match, the API doesn’t return ","type":"text"},{"code":"keywordId","type":"codeVoice"},{"text":" in the attribution response. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"See ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/adgroups-endpoints","isActive":true,"type":"reference"},{"text":" for more information.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"orgId","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"long","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The identifier of the organization that owns the campaign. Your ","type":"text"},{"code":"orgId","type":"codeVoice"},{"text":" is the same as your account in Apple Ads Advanced. ","type":"text"},{"identifier":"spacer","type":"image"},{"text":"Obtain your ","type":"text"},{"code":"orgId","type":"codeVoice"},{"text":" by calling ","type":"text"},{"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-user-ACLs","isActive":true,"type":"reference"},{"text":" in the Apple Ads Platform API.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"supplyPlacement","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"string","type":"text"}],"type":"paragraph"}],[{"inlineContent":[{"text":"The ad placements for a campaign.","type":"text"}],"type":"paragraph"}]]],"type":"table"},{"anchor":"supplyPlacement-descriptions","level":3,"text":"supplyPlacement descriptions","type":"heading"},{"header":"row","rows":[[[{"inlineContent":[{"inlineContent":[{"text":"Value","type":"text"}],"type":"strong"}],"type":"paragraph"}],[{"inlineContent":[{"inlineContent":[{"text":"Description","type":"text"}],"type":"strong"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"APPSTORE_PRODUCT_PAGES","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Product page ads on the App Store allow you to reach users browsing app pages, appearing at the top of the “You Might Also Like” list when users scroll to the bottom.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"APPSTORE_SEARCH_RESULTS","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Search results ads let you reach users when they search for something specific, with an ad in relevant search results.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"APPSTORE_SEARCH_TAB","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Search tab ads let you reach users before they search for something specific, with an ad that appears prominently at the top of the suggested apps list on the Search tab.","type":"text"}],"type":"paragraph"}]],[[{"inlineContent":[{"code":"APPSTORE_TODAY_TAB","type":"codeVoice"}],"type":"paragraph"}],[{"inlineContent":[{"text":"Today tab ads let you reach people on the front page of the App Store, where users start their visit.","type":"text"}],"type":"paragraph"}]]],"type":"table"}],"kind":"content"}],"schemaVersion":{"major":0,"minor":3,"patch":0},"sections":[],"variants":[{"paths":["\/documentation\/adservices\/aaattribution\/attributiontoken()"],"traits":[{"interfaceLanguage":"swift"}]},{"paths":["\/documentation\/adservices\/aaattribution\/attributiontoken()"],"traits":[{"interfaceLanguage":"occ"}]}],"references":{"doc://com.apple.AdServices/documentation/AdServices":{"abstract":[{"text":"Attribute app-download campaigns that originate from the App Store on iOS devices.","type":"text"}],"identifier":"doc:\/\/com.apple.AdServices\/documentation\/AdServices","kind":"symbol","role":"collection","title":"AdServices","type":"topic","url":"\/documentation\/adservices"},"doc://com.apple.AdServices/documentation/AdServices/AAAttribution":{"abstract":[{"text":"The parent class that the framework uses to request a token.","type":"text"}],"fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"identifier","text":"AAAttribution"}],"identifier":"doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttribution","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"AAAttribution"}],"role":"symbol","title":"AAAttribution","type":"topic","url":"\/documentation\/adservices\/aaattribution"},"doc://com.apple.AdServices/documentation/AdServices/AAAttribution/attributionToken()":{"abstract":[{"text":"Generates a token.","type":"text"}],"fragments":[{"kind":"keyword","text":"class"},{"kind":"text","text":" "},{"kind":"keyword","text":"func"},{"kind":"text","text":" "},{"kind":"identifier","text":"attributionToken"},{"kind":"text","text":"() "},{"kind":"keyword","text":"throws"},{"kind":"text","text":" -> "},{"kind":"typeIdentifier","preciseIdentifier":"s:SS","text":"String"}],"identifier":"doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttribution\/attributionToken()","kind":"symbol","navigatorTitle":[{"kind":"text","text":"+ "},{"kind":"identifier","text":"attributionTokenWithError:"}],"role":"symbol","title":"attributionToken()","type":"topic","url":"\/documentation\/adservices\/aaattribution\/attributiontoken()"},"doc://com.apple.AdServices/documentation/AdServices/AAAttributionError":{"abstract":[{"text":"The error code that the parent class issues.","type":"text"}],"fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"AAAttributionError"}],"identifier":"doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttributionError","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"AAAttributionError"}],"role":"symbol","title":"AAAttributionError","type":"topic","url":"\/documentation\/adservices\/aaattributionerror"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API":{"abstract":[{"text":"Programmatically manage App Store and Apple Maps advertising campaigns through a single RESTful API.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API","kind":"symbol","role":"collection","title":"Apple Ads Platform API","type":"topic","url":"\/documentation\/apple-ads-platform-api"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/AppsReportingRequest":{"abstract":[{"text":"Request body for apps reporting queries.","type":"text"}],"fragments":[{"kind":"text","text":"object "},{"kind":"identifier","text":"AppsReportingRequest"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/AppsReportingRequest","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"AppsReportingRequest"}],"role":"symbol","title":"AppsReportingRequest","type":"topic","url":"\/documentation\/apple-ads-platform-api\/appsreportingrequest"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/Get-app-ad-group-reports":{"abstract":[{"text":"Retrieve performance metrics for ad groups.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-ad-group-reports","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"Get app ad group reports"}],"role":"symbol","title":"Ad Groups Report","type":"topic","url":"\/documentation\/apple-ads-platform-api\/get-app-ad-group-reports"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/Get-app-ad-reports":{"abstract":[{"text":"Retrieve performance metrics for ads.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-ad-reports","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"Get app ad reports"}],"role":"symbol","title":"Ads Report","type":"topic","url":"\/documentation\/apple-ads-platform-api\/get-app-ad-reports"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/Get-app-campaign-reports":{"abstract":[{"text":"Retrieve performance metrics for campaigns.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-campaign-reports","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"Get app campaign reports"}],"role":"symbol","title":"Campaigns Report","type":"topic","url":"\/documentation\/apple-ads-platform-api\/get-app-campaign-reports"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/Get-app-keyword-reports":{"abstract":[{"text":"Retrieve performance metrics for keywords.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-app-keyword-reports","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"Get app keyword reports"}],"role":"symbol","title":"Keywords Report","type":"topic","url":"\/documentation\/apple-ads-platform-api\/get-app-keyword-reports"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/Get-user-ACLs":{"abstract":[{"text":"Return the ad accounts and roles accessible to the authenticated API caller.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/Get-user-ACLs","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"Get user ACLs"}],"role":"symbol","title":"Get User ACL","type":"topic","url":"\/documentation\/apple-ads-platform-api\/get-user-acls"},"doc://com.apple.documentation/documentation/Apple-Ads-Platform-API/adgroups-endpoints":{"abstract":[{"text":"Create, retrieve, update, and delete ad groups.","type":"text"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Apple-Ads-Platform-API\/adgroups-endpoints","kind":"article","role":"collectionGroup","title":"Ad Groups Endpoints","type":"topic","url":"\/documentation\/apple-ads-platform-api\/adgroups-endpoints"},"doc://com.apple.documentation/documentation/Swift/String":{"abstract":[{"text":"A Unicode string value that is a collection of characters.","type":"text"}],"fragments":[{"kind":"keyword","text":"struct"},{"kind":"text","text":" "},{"kind":"identifier","text":"String"}],"identifier":"doc:\/\/com.apple.documentation\/documentation\/Swift\/String","kind":"symbol","navigatorTitle":[{"kind":"identifier","text":"String"}],"role":"symbol","title":"String","type":"topic","url":"\/documentation\/swift\/string"},"doc://com.apple.documentation/documentation/technologies":{"abstract":[],"identifier":"doc:\/\/com.apple.documentation\/documentation\/technologies","kind":"technologies","role":"overview","title":"Technologies","type":"topic","url":"\/documentation\/technologies"},"https://ads.apple.com/advanced/":{"identifier":"https:\/\/ads.apple.com\/advanced\/","title":"Apple Ads Advanced","titleInlineContent":[{"text":"Apple Ads Advanced","type":"text"}],"type":"link","url":"https:\/\/ads.apple.com\/advanced\/"},"https://developer.apple.com/documentation/apple-ads-platform-api/appscampaignmetrics":{"identifier":"https:\/\/developer.apple.com\/documentation\/apple-ads-platform-api\/appscampaignmetrics","title":"AppsCampaignMetrics","titleInlineContent":[{"text":"AppsCampaignMetrics","type":"text"}],"type":"link","url":"https:\/\/developer.apple.com\/documentation\/apple-ads-platform-api\/appscampaignmetrics"},"spacer":{"alt":null,"identifier":"spacer","type":"image","variants":[{"traits":["1x","light"],"url":"\/images\/com.apple.AdServices\/spacer.png"}]}},"variantOverrides":[{"patch":[{"op":"replace","path":"\/identifier\/interfaceLanguage","value":"occ"},{"op":"replace","path":"\/metadata\/platforms","value":[{"beta":false,"deprecated":false,"introducedAt":"14.3","name":"iOS","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"14.3","name":"iPadOS","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"14.3","name":"Mac Catalyst","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"11.1","name":"macOS","unavailable":false},{"beta":false,"deprecated":false,"introducedAt":"1.0","name":"visionOS","unavailable":false}]},{"op":"replace","path":"\/metadata\/roleHeading","value":"Type Method"},{"op":"replace","path":"\/metadata\/title","value":"attributionTokenWithError:"},{"op":"replace","path":"\/metadata\/symbolKind","value":"method"},{"op":"replace","path":"\/metadata\/fragments","value":[{"kind":"text","text":"+ "},{"kind":"identifier","text":"attributionTokenWithError:"}]},{"op":"replace","path":"\/hierarchy","value":{"paths":[["doc:\/\/com.apple.documentation\/documentation\/technologies","doc:\/\/com.apple.AdServices\/documentation\/AdServices","doc:\/\/com.apple.AdServices\/documentation\/AdServices\/AAAttribution"]]}},{"op":"add","path":"\/topicSections","value":null},{"op":"add","path":"\/relationshipsSections","value":null},{"op":"add","path":"\/seeAlsoSections","value":null},{"op":"replace","path":"\/primaryContentSections\/0","value":{"declarations":[{"languages":["occ"],"platforms":["iOS","iPadOS","Mac Catalyst","macOS","visionOS"],"tokens":[{"kind":"text","text":"+ ("},{"kind":"typeIdentifier","preciseIdentifier":"c:objc(cs)NSString","text":"NSString"},{"kind":"text","text":" *) "},{"kind":"identifier","text":"attributionTokenWithError:"},{"kind":"text","text":"("},{"kind":"typeIdentifier","preciseIdentifier":"c:objc(cs)NSError","text":"NSError"},{"kind":"text","text":" **) "},{"kind":"internalParam","text":"error"},{"kind":"text","text":";"}]}],"kind":"declarations"}},{"op":"add","path":"\/primaryContentSections\/1","value":{"kind":"parameters","parameters":[{"content":[{"inlineContent":[{"text":"On output, a pointer to an error object that describes why the method failed, or ","type":"text"},{"code":"nil","type":"codeVoice"},{"text":" if no error occurred. If you are not interested in the error information, pass ","type":"text"},{"code":"nil","type":"codeVoice"},{"text":" for this parameter.","type":"text"}],"type":"paragraph"}],"name":"error"}]}},{"op":"replace","path":"\/references\/doc:~1~1com.apple.AdServices~1documentation~1AdServices~1AAAttribution\/title","value":"AAAttribution"},{"op":"replace","path":"\/references\/doc:~1~1com.apple.AdServices~1documentation~1AdServices~1AAAttribution\/fragments","value":[{"kind":"identifier","text":"AAAttribution"}]},{"op":"replace","path":"\/references\/doc:~1~1com.apple.AdServices~1documentation~1AdServices~1AAAttribution\/navigatorTitle","value":[{"kind":"identifier","text":"AAAttribution"}]},{"op":"replace","path":"\/references\/doc:~1~1com.apple.AdServices~1documentation~1AdServices~1AAAttribution~1attributionToken()\/title","value":"attributionTokenWithError:"},{"op":"replace","path":"\/references\/doc:~1~1com.apple.AdServices~1documentation~1AdServices~1AAAttribution~1attributionToken()\/fragments","value":[{"kind":"text","text":"+ "},{"kind":"identifier","text":"attributionTokenWithError:"}]}],"traits":[{"interfaceLanguage":"occ"}]}]}