Skip to content

Latest commit

 

History

History
151 lines (118 loc) · 5.94 KB

source_news_api.md

File metadata and controls

151 lines (118 loc) · 5.94 KB
page_title subcategory description
airbyte_source_news_api Resource - terraform-provider-airbyte
SourceNewsAPI Resource

airbyte_source_news_api (Resource)

SourceNewsAPI Resource

Example Usage

resource "airbyte_source_news_api" "my_source_newsapi" {
  configuration = {
    api_key  = "...my_api_key..."
    category = "sports"
    country  = "ve"
    domains = [
      "..."
    ]
    end_date = "2021-01-01"
    exclude_domains = [
      "..."
    ]
    language = "se"
    search_in = [
      "description"
    ]
    search_query = "+bitcoin OR +crypto"
    sort_by      = "relevancy"
    sources = [
      "..."
    ]
    start_date = "2021-01-01"
  }
  definition_id = "2055c47d-96b3-45fb-b87b-ce89b41640c2"
  name          = "...my_name..."
  secret_id     = "...my_secret_id..."
  workspace_id  = "0cb04faa-3d4c-4274-9b19-99c077dc3d83"
}

Schema

Required

  • configuration (Attributes) (see below for nested schema)
  • name (String) Name of the source e.g. dev-mysql-instance.
  • workspace_id (String)

Optional

  • definition_id (String) The UUID of the connector definition. One of configuration.sourceType or definitionId must be provided. Requires replacement if changed.
  • secret_id (String) Optional secretID obtained through the public API OAuth redirect flow. Requires replacement if changed.

Read-Only

  • created_at (Number)
  • resource_allocation (Attributes) actor or actor definition specific resource requirements. if default is set, these are the requirements that should be set for ALL jobs run for this actor definition. it is overriden by the job type specific configurations. if not set, the platform will use defaults. these values will be overriden by configuration at the connection level. (see below for nested schema)
  • source_id (String)
  • source_type (String)

Nested Schema for configuration

Required:

  • api_key (String, Sensitive) API Key

Optional:

  • category (String) The category you want to get top headlines for. Default: "business"; must be one of ["business", "entertainment", "general", "health", "science", "sports", "technology"]
  • country (String) The 2-letter ISO 3166-1 code of the country you want to get headlines for. You can't mix this with the sources parameter. Default: "us"; must be one of ["ae", "ar", "at", "au", "be", "bg", "br", "ca", "ch", "cn", "co", "cu", "cz", "de", "eg", "fr", "gb", "gr", "hk", "hu", "id", "ie", "il", "in", "it", "jp", "kr", "lt", "lv", "ma", "mx", "my", "ng", "nl", "no", "nz", "ph", "pl", "pt", "ro", "rs", "ru", "sa", "se", "sg", "si", "sk", "th", "tr", "tw", "ua", "us", "ve", "za"]
  • domains (List of String) A comma-seperated string of domains (eg bbc.co.uk, techcrunch.com, engadget.com) to restrict the search to.
  • end_date (String) A date and optional time for the newest article allowed. This should be in ISO 8601 format.
  • exclude_domains (List of String) A comma-seperated string of domains (eg bbc.co.uk, techcrunch.com, engadget.com) to remove from the results.
  • language (String) The 2-letter ISO-639-1 code of the language you want to get headlines for. Possible options: ar de en es fr he it nl no pt ru se ud zh. must be one of ["ar", "de", "en", "es", "fr", "he", "it", "nl", "no", "pt", "ru", "se", "ud", "zh"]
  • search_in (List of String) Where to apply search query. Possible values are: title, description, content.
  • search_query (String) Search query. See https://newsapi.org/docs/endpoints/everything for information.
  • sort_by (String) The order to sort the articles in. Possible options: relevancy, popularity, publishedAt. Default: "publishedAt"; must be one of ["relevancy", "popularity", "publishedAt"]
  • sources (List of String) Identifiers (maximum 20) for the news sources or blogs you want headlines from. Use the /sources endpoint to locate these programmatically or look at the sources index: https://newsapi.com/sources. Will override both country and category.
  • start_date (String) A date and optional time for the oldest article allowed. This should be in ISO 8601 format.

Nested Schema for resource_allocation

Read-Only:

Nested Schema for resource_allocation.default

Read-Only:

  • cpu_limit (String)
  • cpu_request (String)
  • ephemeral_storage_limit (String)
  • ephemeral_storage_request (String)
  • memory_limit (String)
  • memory_request (String)

Nested Schema for resource_allocation.job_specific

Read-Only:

  • job_type (String) enum that describes the different types of jobs that the platform runs. must be one of ["get_spec", "check_connection", "discover_schema", "sync", "reset_connection", "connection_updater", "replicate"]
  • resource_requirements (Attributes) optional resource requirements to run workers (blank for unbounded allocations) (see below for nested schema)

Nested Schema for resource_allocation.job_specific.resource_requirements

Read-Only:

  • cpu_limit (String)
  • cpu_request (String)
  • ephemeral_storage_limit (String)
  • ephemeral_storage_request (String)
  • memory_limit (String)
  • memory_request (String)

Import

Import is supported using the following syntax:

terraform import airbyte_source_news_api.my_airbyte_source_news_api ""