Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

Comments

Fix : Add region support for lg:translate command#995

Merged
boydc2014 merged 1 commit intomainfrom
shuwan/fixTranslate
Sep 29, 2020
Merged

Fix : Add region support for lg:translate command#995
boydc2014 merged 1 commit intomainfrom
shuwan/fixTranslate

Conversation

@cosmicshuai
Copy link
Contributor

@cosmicshuai cosmicshuai commented Sep 29, 2020

Due to the change of Azure Text Translate API (API Ref).
Now it requires a Ocp-Apim-Subscription-Region in the headers.
In this PR, a new flag "region" is added. The value of region is the location in the azure keys and endpoints page, see the picture below
image

Now the command should be called like:
bf lg:translate -i inputFile --srclang=src-lang --tgtlang=tgt-lang --translatekey=subscription-key --region=subscription-region

@boydc2014 boydc2014 merged commit b1d4cc1 into main Sep 29, 2020
@cosmicshuai cosmicshuai changed the title Fix lg:translate command failure Fix : Add region support for lg:translate command Sep 29, 2020
@cosmicshuai cosmicshuai deleted the shuwan/fixTranslate branch September 29, 2020 10:32
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants