Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Source Bing Ads: support oauth #6294

Closed
1 task done
Tracked by #7341 ...
sherifnada opened this issue Sep 20, 2021 · 7 comments · Fixed by #12937
Closed
1 task done
Tracked by #7341 ...

Source Bing Ads: support oauth #6294

sherifnada opened this issue Sep 20, 2021 · 7 comments · Fixed by #12937

Comments

@sherifnada
Copy link
Contributor

sherifnada commented Sep 20, 2021

Tell us about the problem you're trying to solve

With the release of Airbyte Cloud, we need to start supporting Oauth for this connector, since it's the recommended way of authenticating users into a SaaS application.

If this connector doesn't support oauth already (i.e: doesn't accept a client_id and client_secret) then we need to update its spec to accept those parameters. There are two ways to do this:

If the connector already supports some auth mechanism like api_key, I suggest that this be a oneof nested inside a top-level field called "authentication":

{ authentication: { type: object oneOf: [ // api key, // oauth ] } }

If the connector only supports webflow oauth, then no changes are needed to the properties format and we will only need to add annotations.

See the connector spec reference in the docs for reference on how a oneof can be implemented.

This should be done in a backwards compatible manner i.e: users currently supplying authentication info in the config's top-level should not be impacted by this change.

Acceptance Criteria

  1. The connector supports oauth webflow authentication with client_id/client_secret in a backwards compatible manner
  2. Oauth properties are annotated properly. See this PR for an example
@sherifnada sherifnada added area/oauth area/connectors Connector related issues labels Sep 20, 2021
@sherifnada sherifnada changed the title Source Bing: support oauth Source Bing Ads: support oauth Sep 20, 2021
@cheyura cheyura self-assigned this Sep 25, 2021
@cheyura
Copy link

cheyura commented Sep 25, 2021

@sherifnada Public App with appropriate branding created, authorization flow checked. LastPass - Bing Ads OAUth Developer App

@annalvova05 annalvova05 self-assigned this Sep 29, 2021
@annalvova05 annalvova05 linked a pull request Oct 6, 2021 that will close this issue
13 tasks
@antixar
Copy link
Contributor

antixar commented Nov 4, 2021

BingAds docs
Necessary scopes values: offline_access user.read

Example of consent url: https://login.microsoftonline.com/common/oauth2/v2.0/authorize?
client_id=
&response_type=code
&redirect_uri=
&response_mode=query
&scope=https://ads.microsoft.com/offline_access%20user.read

Example of token url: https://login.microsoftonline.com/common/oauth2/v2.0/token
-ContentType application/x-www-form-urlencoded
-Method POST
-Body "client_id=$clientId&scope=https://ads.microsoft.com/offline_access%20user.read&code=_code_&grant_type=authorization_code&redirect_uri=_url_"

where accounts, customer_id, developer_token, user_id, reports_start_date, hourly_reports, daily_reports, weekly_reports, monthly_reports should be forwarded from UI part

The BingAds oAuth2 implementation returns refresh_token

@misteryeo
Copy link
Contributor

@annalvova05 What is this blocked on?

@bazarnov
Copy link
Collaborator

@misteryeo
No blockers at this moment, will work on it. Previously we were blocked by passing the additional OAuth parameters to java flow, which is no longer a blocker.

@bazarnov bazarnov moved this from Blocked to Implementation in progress in GL Roadmap May 12, 2022
@misteryeo
Copy link
Contributor

@bazarnov can we make sure to update the status? It's currently listed as Blocked :)

cc: @oustynova

@bazarnov
Copy link
Collaborator

bazarnov commented May 17, 2022

@misteryeo
What status should I update?
The oAuth is implemented and tested using public client, within this PR - #12937

@misteryeo
Copy link
Contributor

Source Bing Ads: support oauth · Issue #6294 · airbytehqairbyte 2022-05-17 at 4 49 44 PM
@bazarnov

@midavadim midavadim moved this from In review (internal) to Done in GL Roadmap Jun 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
8 participants