View source: R/create_glossary.R
create_glossary | R Documentation |
create_glossary
creates a glossary for a language pair using the DeepL API Pro.
create_glossary(
name,
source_lang,
target_lang,
entries_source_lang,
entries_target_lang,
return_tibble = F,
auth_key
)
name |
A string specifying the name to be associated with the glossary. |
source_lang |
A string specifying the source language code. |
target_lang |
A string specifying the target language code. |
entries_source_lang |
A character vector containing the glossary entries in the source language. |
entries_target_lang |
A character vector containing the glossary entries in the target language. |
return_tibble |
Logical. If |
auth_key |
A string representing the authentication key for the DeepL API Pro.
If not provided, the function will attempt to retrieve the key from the environment
variable |
To use this function, you must obtain an authentication key by registering for a DeepL API Pro account at DeepL API Pro. The function sends a request to create a glossary and returns the result in a structured format.
DeepL API Documentation on Glossaries
## Not run:
glossary_english <- c("Hello", "Goodbye")
glossary_swiss_german <- c("Grüezi", "Adiöö")
create_glossary(
name = "My Glossary",
source_lang = "en",
target_lang = "de",
entries_source_lang = glossary_english,
entries_target_lang = glossary_swiss_german
)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.