Hi,
I have created 3 receive only customers accounts in sandbox and also done one transaction, but now that I want to create the unverified and verified customers I think there is no way I can do that. I have searched in the customers option, but I can not find the step to move on.
Hi @Diamufuama – I’m afraid creating Unverified and Verified Customer types isn’t supported through the Dashboard. You would have to call the Dwolla API in order to create these Customer types.
You can find more information on creating Customers via the API in our Docs!
Here’s also a helpful guide that walks you through creating an authorization which is needed to start calling the API.
Let us know if you come across any questions, we’d be happy to help!
Hi Pedro – It looks like the value you’re passing in the Authorization header might be wrong. Are you able to confirm that you are passing the word Basic followed by a space and a base64-encoded string client_id:client_secret as the value like in the following example?
Hi, this is also happening to me, even when creating the token from the “Create Token” button in the Applications page. I thought maybe I was sending the request wrong but I was able to create a receive-only customer with it.
@shreya I’m making the request with Postman, don’t know if that has to do something with the result. The Postman exported curl request:
spencer
(Spencer Hunter - Lead Developer Advocate @ Dwolla)
6
Hi @armando, just wanted to confirm, the resulting error you’re receiving from the curl request shown above is {“code”:“InvalidCredentials”,“message”:“Missing or invalid Authorization header.”}
Hi, sorry, the response I’m getting is a 403 with the message: “The supplied credentials are not authorized for this resource.”
spencer
(Spencer Hunter - Lead Developer Advocate @ Dwolla)
8
Hi @armando, I believe I found the culprit which was a permissions issue on your Sandbox account. This should be resolved now. Would you be able to give this request another shot?
It’s working now. Thanks a lot! Finally, Is there a way to convert receive-only users to unverified, or I just have to deactivate them and create them back? Thanks again!
I am having this same issue as well, I have received the same error, for the Authorization: Basic Base64(client_id:client_secret) am I suppose to add this in my index.js as is or should I assign it to a variable?
Should i stick that in the here somewhere: app.get("/create-customer", function (req, res) { generateClientToken("customer.create").then((cRes) => { res.status(200).render(create-customer, { token: cRes.token }); }); });
i am stumped!
Hi @akikoLPF – Are you using the above value for the Authorization header as is? If so, you’d need to convert the “your_client_id:your_client_secret” to Base 64 and plug that value in the Authorization header after "Basic ".
Are you using one of our SDKs for making calls to the API? If so, you might not even need to handle the token creation as some of our SDKs (like dwolla-v2-node) handle token creation for you; you would just need to instantiate the Dwolla client.
Uhmm, so I have the proper SDK installed, I am currently using node.js one. However, It is still giving me the same error messages of invalid auth header.
What I am specifically asking is how I am supposed to have the Authorization: Basic Base64(client_id: secret) stored. Like does it need to be stored in a variable? like this: let auth = Authorization: Basic Base64(client_id: secret) or is this supposed to be located in another file because right now it is in my index.js file.
No, you shouldn’t need to save it into a variable. The “Authorization” is meant to be sent to Dwolla as an API request header when creating an access-token, like so,
POST https://api-sandbox.dwolla.com/token
Authorization: Basic YkVEMGJMaEFhb0pDamplbmFPVjNwMDZSeE9Eb2pyOUNFUzN1dldXcXUyeE9RYk9GeUE6WEZ0bmJIbXR3dXEwNVI1Yk91WmVOWHlqcW9RelNSc21zUU5qelFOZUFZUlRIbmhHRGw=
Content-Type: application/x-www-form-urlencoded
grant_type=client_credentials
However, since you’re using the Node SDK, you do not have to set the Authorization header at all. When you instantiate the Client in your index.js file, the token is automatically generated about every 60 minutes, before the previous one expires. You can also reference this file from the drop-ins-examples repo since it uses our Node sdk under the hood as well.
So this is where I am very confused because I have the SDK installed, and i am using this exact example repo here. Yet, I am still getting the Dwolla API:{“code”:“InvalidCredentials”,“message”:“Missing or invalid Authorization header.”} error.
I am not sure what I am missing or doing wrong? Should I specifically be making a post request in index.js to Dwolla in order for this error to be fixed?
Hmm…it indicates that the issue has to do with what is set as the Authorization header value. Would you be able to share in a DM what your key and secret are, as well as what is generated as the Base64(client_id: secret) value?
You can also skip generating tokens if you’re using the node SDK. The SDK generates tokens automatically once you instantiate the Client as in the following code snippet.
Are you able to make calls to other endpoints from the same file (index.js) where you are instantiating the client with the following code?
var Client = require("dwolla-v2").Client;
var dwolla = new Client({
key: process.env.DWOLLA_APP_KEY,
secret: process.env.DWOLLA_APP_SECRET,
environment: "sandbox", // defaults to 'production'
});