google_api_page_speed_online v0.0.1 GoogleApi.PageSpeedOnline.V2.Api.Pagespeedapi View Source

API calls for all endpoints tagged Pagespeedapi.

Link to this section Summary

Functions

Runs PageSpeed analysis on the page at the specified URL, and returns PageSpeed scores, a list of suggestions to make that page faster, and other information

Link to this section Functions

Link to this function pagespeedonline_pagespeedapi_runpagespeed(connection, url, opts \\ []) View Source
pagespeedonline_pagespeedapi_runpagespeed(Tesla.Env.client, String.t, keyword) ::
  {:ok, GoogleApi.PageSpeedOnline.V2.Model.Result.t} |
  {:error, Tesla.Env.t}

Runs PageSpeed analysis on the page at the specified URL, and returns PageSpeed scores, a list of suggestions to make that page faster, and other information.

Parameters

  • connection (GoogleApi.PageSpeedOnline.V2.Connection): Connection to server
  • url (String): The URL to fetch and analyze
  • opts (KeywordList): [optional] Optional parameters

    • :alt (String): Data format for the response.
    • :fields (String): Selector specifying which fields to include in a partial response.
    • :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
    • :oauth_token (String): OAuth 2.0 token for the current user.
    • :pretty_print (Boolean): Returns response with indentations and line breaks.
    • :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters. Overrides userIp if both are provided.
    • :user_ip (String): IP address of the site where the request originates. Use this if you want to enforce per-user limits.
    • :filter_third_party_resources (Boolean): Indicates if third party resources should be filtered out before PageSpeed analysis.
    • :locale (String): The locale used to localize formatted results
    • :rule (List[String]): A PageSpeed rule to run; if none are given, all rules are run
    • :screenshot (Boolean): Indicates if binary data containing a screenshot should be included
    • :strategy (String): The analysis strategy to use

Returns

{:ok, %GoogleApi.PageSpeedOnline.V2.Model.Result{}} on success {:error, info} on failure