openapi: 3.2.0 info: title: Google AdMob Ad Sources API version: v1beta description: 'The AdMob API allows publishers to programmatically get information about their AdMob account. ' contact: name: Google url: https://developers.google.com/admob/api/ termsOfService: https://developers.google.com/terms license: name: Google APIs Terms of Service url: https://developers.google.com/terms x-discovery-revision: '20260731' x-discovery-source: https://admob.googleapis.com/$discovery/rest?version=v1beta servers: - url: https://admob.googleapis.com description: Google AdMob API security: - GoogleOAuth2: - https://www.googleapis.com/auth/admob.readonly - https://www.googleapis.com/auth/admob.report tags: - name: adSources paths: /v1beta/accounts/{accountsId}/adSources: get: operationId: accounts_adSources_list summary: List the ad sources. description: List the ad sources. tags: - adSources x-resource-name-parameter: parent: pattern: ^accounts/[^/]+$ description: 'Required. The parent which owns this collection of ad sources. Format: accounts/{publisher_id}' parameters: - name: pageSize in: query required: false schema: type: integer format: int32 description: The maximum number of ad sources to return. If unspecified or 0, at most 10,000 ad sources will be returned. The maximum value is 20,000; values above 10,000 will be coerced to 20,000. - name: pageToken in: query required: false schema: type: string description: A page token, received from a previous `ListAdSources` call. Provide this to retrieve the subsequent page. - name: accountsId in: path required: true schema: type: string description: Path segment of the resource name. responses: '200': description: Successful response content: application/json: schema: $ref: '#/components/schemas/ListAdSourcesResponse' '400': description: INVALID_ARGUMENT — malformed request, unknown publisher id, or incompatible report metrics/dimensions. content: application/json: schema: $ref: '#/components/schemas/GoogleRpcStatus' '401': description: UNAUTHENTICATED — missing or invalid OAuth 2.0 access token. content: application/json: schema: $ref: '#/components/schemas/GoogleRpcStatus' '403': description: PERMISSION_DENIED — AdMob API not enabled on the project, or the effective user lacks access to the resource. content: application/json: schema: $ref: '#/components/schemas/GoogleRpcStatus' '429': description: RESOURCE_EXHAUSTED — per-project quota exceeded. content: application/json: schema: $ref: '#/components/schemas/GoogleRpcStatus' '500': description: INTERNAL — unexpected server error. content: application/json: schema: $ref: '#/components/schemas/GoogleRpcStatus' security: - GoogleOAuth2: - https://www.googleapis.com/auth/admob.readonly - https://www.googleapis.com/auth/admob.report components: schemas: AdSource: type: object description: Definition of a mediation ad source. properties: name: type: string description: 'Resource name of this ad source. Format is: accounts/{publisher_id}/adSources/{ad_source_id}' title: type: string description: Display name of this ad source. adSourceId: type: string description: ID of this ad source. GoogleRpcStatus: type: object description: Canonical Google API error envelope (google.rpc.Status), returned inside an `error` wrapper. properties: code: type: integer description: The status code, which should be an enum value of google.rpc.Code. message: type: string description: A developer-facing error message in English. status: type: string description: The canonical error reason, e.g. INVALID_ARGUMENT, RESOURCE_EXHAUSTED. details: type: array items: type: object description: A list of messages that carry the error details. x-source: Derived from Google's documented AdMob error responses at https://developers.google.com/admob/api/v1/errors; not present in the Discovery Document. ListAdSourcesResponse: type: object description: Response for the ListAdSourcesRequest. properties: adSources: type: array description: The ad sources. items: $ref: '#/components/schemas/AdSource' nextPageToken: type: string description: Used to set the `page_token` in the `ListAdSourcesRequest` to retrieve the next page. If this field is omitted, there are no subsequent pages. securitySchemes: GoogleOAuth2: type: oauth2 description: Google OAuth 2.0 user authorization. AdMob does not support service accounts. flows: authorizationCode: authorizationUrl: https://accounts.google.com/o/oauth2/v2/auth tokenUrl: https://oauth2.googleapis.com/token scopes: https://www.googleapis.com/auth/admob.readonly: See your AdMob data https://www.googleapis.com/auth/admob.report: See your AdMob data externalDocs: description: AdMob API documentation url: https://developers.google.com/admob/api/