get_volume_data: Retrieves search volume data of the provided search queries

View source: R/search_volume.R

get_volume_dataR Documentation

Retrieves search volume data of the provided search queries

Description

Calls Marketing Miner Profilers API endpoint '/keywords/search-volume-data'. If a cache exists, the function reads it first and calls the API only for queries that are not cached.

Usage

get_volume_data(
  query,
  lang = NULL,
  api_key = Sys.getenv("MARKETING_MINER_API_KEY"),
  cache = TRUE,
  cache_path = "mminer-cache"
)

Arguments

query

Queries to retrieve volume data for as a character vector.

lang

A language (actually a country) abbreviation as a character vector of length 1. For instance "us", "gb", "cs", "sk" or "pl".

api_key

Your Marketing Miner API key. Defaults to the environment variable named "MARKETING_MINER_API_KEY".

cache

A logical value stating whether the result should be cached. Dafaults to "mminer-cache" in working directory.

cache_path

Path to the directory with the cache. Defaults to the 'mminer-cache' in the current working directory.

Details

API calls are charged according to https://help.marketingminer.com/en/article/profilers-api/. In the time of writing it was 3 credits per keyword.

Value

A tibble (data frame) with search volume data for the provided queries. Rows are ordered the same as the provided queries.


MarekProkop/mminer documentation built on June 14, 2022, 12:41 a.m.