DocuSign: SIGNATURE_PROVIDER_INVALID_FOR_NONSBS - docusignapi

I'm trying to integrate Docusign with an Unqork app. I am trying to place the sample request that was given in createEnvelope REST API for SBS digital signature, with an embedded signing ceremony.
While trying to invoke the API, got this error:
executionError: {type: "integratorError",…}
code: 412
component: "pluginCreateEnvelope"
message: {,…}
executionError: {type: "integratorError", url: "http://localhost:43235/fbu/uapi/services/Docusign-Sandbox/execute",…}
code: 400
component: "pluginCreateEnvelope"
message: {errorCode: "SIGNATURE_PROVIDER_INVALID_FOR_NONSBS",…}
errorCode: "SIGNATURE_PROVIDER_INVALID_FOR_NONSBS"
message: "Signature providers are not valid for this recipient. Standards Based Signatures must be enabled for the sending account. Envelope is not configured for support of recipient signing providers"
type: "integratorError"
url: "http://localhost:43235/fbu/uapi/services/Docusign-Sandbox/execute"
type: "integratorError"
url: "http://localhost:43235/fbu/uapi/modules/620cbdc72b8a8801b9b67967/execute"
Can someone help how I can fix this?

Docusign demo accounts don't have SBS enabled by default. To fix your error you have to get in contact with your account team/sales team so they can add this to your account.
As an alternative you can remove "recipientSignatureProviders" from your envelopes in the demo environment and only use it with your production account.

Related

How to test Easypaisa Sandbox API?

I am trying Easypaisa sandbox API to implement bill payment from this site:
API:
https://api.eu-de.apiconnect.appdomain.cloud/easypaisaapigw-telenorbankpk-tmbdev/dev-catalog
path:
POST /GetBillCompanies
But it is throwing error:
httpCode: '401',
httpMessage: 'Unauthorized',
moreInformation: 'Invalid client id or secret.'
Although I am providing a valid client id and secret. I tried this on postman and in the node.js program.

DocuSign LoginInformation

I'm new to DocuSign API. I'm getting "com.docusign.esign.client.ApiException: Error while requesting server, received a non successful HTTP code 404 with response Body: '' "
during execution using demo sandbox. I'm using docusign-java-client.
Please help me in this.
Check out the Java examples:
Authorization code grant
JWT grant

Trying O365 Authentication in Xamarin forms app

We are new to O365 Authentication and trying to authenticate the user.
Here i am getting this error while trying to login with, office 365.
Create app in active directory add app id and return urls in app, and this is the document I followed, https://blog.xamarin.com/put-adal-xamarin-forms/
here is the error we are getting,
AADSTS70002: The request body must contain the following parameter: 'client_secret or client_assertion'
Trace ID: e580114e-2dd9-4cc4-b903-6cef743a2900
Correlation ID: 6e58ff9d-bea4-4ad3-9fe3-e27c92fc9597
Timestamp: 2018-12-05 12:51:23Z
{System.Net.Http.HttpRequestException: Response status code does not indicate success: 401 (Unauthorized). ---> Microsoft.IdentityModel.Clients.ActiveDirectory.AdalException: {"error":"invalid_client","error_description":"AADSTS70002: The request body must contain the following parameter: 'client_secret or client_assertion'\r\nTrace ID: e580114e-2dd9-4cc4-b903-6cef743a2900\r\nCorrelation ID: 6e58ff9d-bea4-4ad3-9fe3-e27c92fc9597\r\nTimestamp: 2018-12-05 12:51:23Z","error_codes":[70002],"timestamp":"2018-12-05 12:51:23Z","trace_id":"e580114e-2dd9-4cc4-b903-6cef743a2900","correlation_id":"6e58ff9d-bea4-4ad3-9fe3-e27c92fc9597"}: Unknown error
--- End of inner exception stack trace ---}
Ok ,Maybe you have registered your app as a confidential client (web app or web api).
You cannot authenticate with username and password when the app is a confidential client. Only public clients, sometimes known as native clients, can do U/P authentication.
Trying to Change to native client.
Refer to this link to try

Invalid Delegation Token. Invalid national Cloud ID (1) is specified

We have an O365 tenant, everything is configured out of the box. The tenant is placed in the German cloud and not in global (office.de).
We also developed an Office Add-in that authorize access to sharepoint using OAuth 2.0.
First, we initiate a request for a code to this url:
http://login.microsoftonline.com/common/oauth2/authorize?response_type=code&client_id=client_id&redirect_uri=redirect_uri&state=state
and we get all values back including the code.
Then, we initiate a request for the Discovery Service to discover the services using this url:
https://login.windows.net/common/oauth2/token?client_id=client_id&redirect_uri=redirect_uri&resource=https://api.office.com/discovery/&grant_type=authorization_code&code=code
In the global cloud everything is ok and we get the list of services we need but in the German cloud we get the following error:
{
"error": "invalid_grant",
"error_description": "AADSTS90051: Invalid Delegation Token. Invalid national Cloud ID (1) is specified.\r\nTrace ID: 52f8aa2b-9f98-4ba6-b778-c0ba484a3c00\r\nCorrelation ID: 67100192-82c8-41ea-a5ca-fd9872caaf2e\r\nTimestamp: 2018-02-08 06:31:18Z",
"error_codes": [
90051
],
"timestamp": "2018-02-08 06:31:18Z",
"trace_id": "52f8aa2b-9f98-4ba6-b778-c0ba484a3c00",
"correlation_id": "67100192-82c8-41ea-a5ca-fd9872caaf2e"
}
The same error occurs when we try to change the url to https://login.windows.de/common/oauth2/token
I think that you can use client crendetials flow to achieve that:
1.Request the access token for the Office Discovery service API:
POST https://login.microsoftonline.de/{{yourtenantId}}/oauth2/token?client_id={{client_id}}&client_secret={{client_secret}}&grant_type=client_credentials&resource=https://api.office.com/discovery/
2.Use the access token in the head and use the Office Discovery API:
Additional: If you want to get id_token and use it, try to use https://login.microsoftonline.de as the AAD Athorization endpoint in your request. I didn't test, but it should work.
Hope this helps!

Outlook notification subscription using Azure Webhook Domain Not Found

I am working on Creating a push notification for inbox messages to be sent to my azure webhook.
I have been following the documentation as a reference. Till now I have been able to create and register my app using the Azure app registration. I got the client_id and client_secret accordingly.
Shared below are the postman requests I made to first get the access code and then access_token and refresh_token from the Oauth authorization endpoints -
Getting the access code -
Endpoint - https://login.microsoftonline.com/{tenant}/oauth2/authorize
Authorization Type – Oauth 2.0
Headers –
Content Type: application/x-www-form-urlencoded
Body –
response_type: code
client_id: myClientId
redirect_uri: https://app.getpostman.com/oauth2/callback
response_mode: query
scope: https://outlook.office.com/mail.read
Getting the access_token -
Endpoint –
https://login.microsoftonline.com/{tenant}/oauth2/token
Authorization Type – Oauth 2.0
Headers –
Content Type: application/x-www-form-urlencoded
Body –
code: **********access_code***************
client_id: myClientId
scope: https://outlook.office.com/mail.read
grant_type: authorization_code
client_secret: *********client_secret*********
redirect_uri: https://app.getpostman.com/oauth2/callback
resource: myClientId
Now, as mentioned in the documentation, I am posting the following request for creating the subscription (using Fiddler) -
Endpoint –
https://outlook.office.com/api/v2.0/me/subscriptions
Headers –
Authorization: Bearer access_token_got_in_the_response_above
Content Type: application/json
Body –
#odata.type: #Microsoft.OutlookServices.PushSubscription
Resource: https://outlook.office.com/api/v2.0/me/mailfolders('inbox')/messages
NotificationURL: https://myAzureFunctionApp.azurewebsites.net/api/HttpNotificationHandler
ChangeType: authorization_code
The problem is that the response I am getting is a 404 Not Found. More specifically, X-CasErrorCode: DomainNotFound. I have double checked to make sure there are no typos in any specification.
To give some more Info, I had previously tried this and was successful in creating the subscription for my personal hotmail account. The user I am stuck with has been added to the Azure Active Directory as a guest user under the same tenant my app has been registered.
UPDATE
Here are some more questions that might be useful -
The email address is say email1#contoso.com, and the tenant is ABCcontoso.onmicrosoft.com. Will it make any difference?
The user is not added to the user group using this application in the Azure Active Directory app registration section, the only user shown is the admin who had registered the app. Is this required?
The app was registered on the Microsoft App Registration Portal. But it is reflected in the Azure Active Directory under the tenant. So, is hitting the OAuth2 v1.0 endpoint correct?
What should be the endpoint for creating a notification subscription for a work/organization account having office 365 subscription? The current endpoint https://outlook.office.com/api/v2.0/me/subscriptions uses v2.0, but the token provided is by v1.0 endpoint (if I understand it correctly).
Any help is appreciated.

Resources