logicapps icon indicating copy to clipboard operation
logicapps copied to clipboard

Twitter connection with BYOA: Failed to login. Response status code does not indicate success: 401 (Unauthorized)

Open abatishchev opened this issue 1 year ago • 9 comments

Describe the Bug with repro steps

  1. Add action "Post a tweet"
  2. Provide connection's name
  3. Paste "Consumer API Key" from Twitter Dev Portal to field "Consumer Key"
  4. Paste "Consumer API Key Secret" to "Consumer Secret"
  5. Click "Sign In"
  6. Observe a pop-up window appearing and disappearing quickly
  7. Observe an error:

Failed to login. Response status code does not indicate success: 401 (Unauthorized)

What type of Logic App Is this happening in?

Consumption (Portal)

Are you using new designer or old designer

New Designer

Did you refer to the TSG before filing this issue? https://aka.ms/lauxtsg

Yes

Workflow JSON

No response

Screenshots or Videos

image

Browser

Edge version 122.0.2365.92

Additional context

Demo request "Create a Tweet" on public Postman workspace requires 4 secrets, not 2:

  1. Consumer Key
  2. Consumer Secret
  3. Token
  4. Token Secret

and works even from a simple PowerShell command:

$headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]"
$headers.Add("Content-Type", "application/json")
$headers.Add("Authorization", "OAuth oauth_consumer_key=`"...`", oauth_token=`"...`", oauth_signature_method=`"HMAC-SHA1`",oauth_timestamp=`"...`", oauth_nonce=`"...`" ,oauth_version=`"1.0`", oauth_signature=`"...`"")

$body = @"
{
    `"text`": `"...`"
}
"@

$response = Invoke-RestMethod 'https://api.twitter.com/2/tweets' -Method 'POST' -Headers $headers -Body $body
$response | ConvertTo-Json

AB#27399144

abatishchev avatar Mar 29 '24 16:03 abatishchev

Moved this to our backend repo/issues list. This looks like it's an issue with the connector.

hartra344 avatar Mar 29 '24 18:03 hartra344

Filed an incident per @rarayudu

abatishchev avatar Apr 18 '24 16:04 abatishchev

This issue is stale because it has been open for 45 days with no activity.

github-actions[bot] avatar Jun 02 '24 17:06 github-actions[bot]

I'm investigating this issue now, will post an update here once I've done some log spelunking

deanward81 avatar Jun 06 '24 10:06 deanward81

This issue is stale because it has been open for 45 days with no activity.

github-actions[bot] avatar Jul 21 '24 11:07 github-actions[bot]

Looking into this again today

deanward81 avatar Jul 24 '24 09:07 deanward81

This issue is stale because it has been open for 45 days with no activity.

github-actions[bot] avatar Sep 07 '24 11:09 github-actions[bot]

Nearly there, expect to get to the bottom of this, this week

deanward81 avatar Sep 09 '24 19:09 deanward81

This issue is stale because it has been open for 45 days with no activity.

github-actions[bot] avatar Oct 24 '24 20:10 github-actions[bot]

This issue was closed because it has been inactive for 14 days since being marked as stale.

github-actions[bot] avatar Nov 07 '24 20:11 github-actions[bot]

Reopening, still under investigation @hartra344 can you re-open please?

deanward81 avatar Nov 07 '24 20:11 deanward81