mindat_extract_response_body {OpenMindat}R Documentation

mindat_extract_response_body

Description

.

Usage

mindat_extract_response_body (response)

Arguments

response

response json

Value

if status of the response is sucess (200),return the all_data_text(the content of response). Otherwise,report the errors.

Examples

## Not run: 
library(httr)
uri<- "https://api.mindat.org/geomaterials/?id__in=&hardness_min=9.3&fields=name,+
hardness&page_size=1500"
api_token<- "9ce67655d74bcd981e937be80dcea9cb"
response <- GET(uri,add_headers('Authorization'= paste('Token ',api_token,sep = "")))
raw_data <- mindat_extract_response_body(response)

## End(Not run)

[Package OpenMindat version 1.0.0 Index]