{"id":21662934,"url":"https://github.com/zunda-pixel/googleads-swift","last_synced_at":"2025-03-20T05:49:17.770Z","repository":{"id":264117127,"uuid":"892399477","full_name":"zunda-pixel/googleads-swift","owner":"zunda-pixel","description":"GoogleAds REST API Swift Client","archived":false,"fork":false,"pushed_at":"2025-03-13T04:43:25.000Z","size":29,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-13T05:28:01.974Z","etag":null,"topics":["google","googleads","swift","swift-package-manager"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zunda-pixel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-11-22T03:19:35.000Z","updated_at":"2025-03-13T04:43:04.000Z","dependencies_parsed_at":"2025-02-28T15:46:51.835Z","dependency_job_id":"5dfc207c-d239-41d9-bca5-c8f0e5ed88bf","html_url":"https://github.com/zunda-pixel/googleads-swift","commit_stats":null,"previous_names":["zunda-pixel/googleads-swift"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zunda-pixel%2Fgoogleads-swift","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zunda-pixel%2Fgoogleads-swift/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zunda-pixel%2Fgoogleads-swift/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zunda-pixel%2Fgoogleads-swift/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zunda-pixel","download_url":"https://codeload.github.com/zunda-pixel/googleads-swift/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244560373,"owners_count":20472219,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["google","googleads","swift","swift-package-manager"],"created_at":"2024-11-25T10:18:46.584Z","updated_at":"2025-03-20T05:49:17.747Z","avatar_url":"https://github.com/zunda-pixel.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GoogleAds\n\n[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fzunda-pixel%2Fgoogleads-swift%2Fbadge%3Ftype%3Dswift-versions)](https://swiftpackageindex.com/zunda-pixel/googleads-swift)\n\n[![](https://img.shields.io/endpoint?url=https%3A%2F%2Fswiftpackageindex.com%2Fapi%2Fpackages%2Fzunda-pixel%2Fgoogleads-swift%2Fbadge%3Ftype%3Dplatforms)](https://swiftpackageindex.com/zunda-pixel/googleads-swift)\n\n```swift\nimport Foundation\nimport GoogleAds\n\nlet client = GoogleAdsClient(\n  httpClient: .urlSession(.shared),\n  isTest: true,\n  clientId: \"ca-app-pub-3940256099942544\",\n  language: \"ja\",\n  userAgent:\n    \"Mozilla/5.0 (iPhone; CPU iPhone OS 18_2 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148\"\n)\nlet ads = try await client.fetchNativeAds(\n  slotName: \"3986624511\",\n  maxCount: 10,\n  nativeVersion: 3,\n  templates: [.small, .medium, .large, .video]\n)\n```\n\n\n```swift\nlet ads = [\n  Ad(\n    uuid: EF9886D9-911F-31DE-4992-C018203BBD08,\n    type: \"native\",\n    headline: \"Flood–It!\",\n    body: \"Flood-it! Install Flood-It App for free! Free Popular Casual Game\",\n    image: Image(\n      url: https://lh3.googleusercontent.com/7pSuz6KU_tyRCYutzMT9fQ6zDwl1Lm4jGMjFpb,\n      width: 270,\n      height: 480,\n      scale: 1,\n      isTransparent: false,\n      isAnimated: false\n    ),\n    secondaryImage: nil,\n    trackingUrlsAndAction: TrackingUrlsAndAction(\n      clickActions: [\n        ClickActions(\n          type: 1,\n          url: https://apps.apple.com/app/id476943146?mt=8,\n          u2FinalUrl: https://apps.apple.com/app/id476943146?mt=8\n        )\n      ],\n      impressionTrackingUrls: [\n        https://pagead2.googleadservices.com/pagead/adview?ai=CztFupMpBZ4vaDb3ys8IPjrW5sA0A\n      ],\n      googleClickTrackingUrl: https://googleads.g.doubleclick.net/aclk?sa=L\u0026ai=Ct2ZA\u0026adurl=https://apps.apple.com/app/id476943146%3Fmt%3D8,\n      creativeConversionUrlWithoutLabel: https://googleads.g.doubleclick.net/pagead/conversion/?ai=Ct7elpMpBZ4vaDb3ys8,\n      useAppStoreOverlay: false\n    ),\n    template: .small,\n    callToCction: \"INSTALL\",\n    attribution: nil,\n    images: [\n      Image(\n        url: https://lh3.googleusercontent.com/7pSuz6KU_tyRCYutzMT9fQ6zDwl1Lm4jGMjFpb8vqMEIUqxRR63SC7x7EJoXv0vBFCNCgF_E=w270-h480-n-e7-l80-rj,\n        width: 270,\n        height: 480,\n        scale: 1,\n        isTransparent: false,\n        isAnimated: false\n      ),\n      Image(\n        url: https://lh3.googleusercontent.com/z9J99SJgooFyDQi99XX4u4Gwj,\n        width: 270,\n        height: 480),\n        scale: 1),\n        isTransparent: false,\n        isAnimated: false\n      ),\n    ],\n    video: nil,\n    adType: AdType.appStore(\n      appIcon: Image(\n        url: https://lh3.googleusercontent.com/FmxHh96FckkqyE16a6iMNnotA2vv0Jra5UHQ1EivFVDus-aqa25ksdBBIfs3KlXKfdaOB71Xtw=w128-h128-n-e7,\n        width: 128,\n        height: 128,\n        scale: 1,\n        isTransparent: true,\n        isAnimated: nil\n      ),\n      price: \"FREE\",\n      rating: 3.5842702,\n      store: \"App Store\",\n      appId: \"476943146\"\n    )\n  )\n]\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzunda-pixel%2Fgoogleads-swift","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzunda-pixel%2Fgoogleads-swift","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzunda-pixel%2Fgoogleads-swift/lists"}