Regarding Duo integration with Jira, Confluence & bitbucket using JAVA

Hello there,

I am looking to implement a PUSH notification with a DUO mobile feature for my customer. I found the below link using which support is possible. But I am facing some issues with this.

I used /enroll endpoint for generating activation_code & activation_barcode for any user. After calling this endpoint it will either create new codes or give the user already exist error.

As the same user exists on Jira, Confluence & Bitbucket with the same username. So if I call /enroll endpoint from a different location then it will create a new user only once & for the rest calls, it gives the user already exist error. I can solve this issue by making some changes to the username. But it will create a new user on DUO with a different username. So this solution is acceptable.

Is there any way to solve this? Do you have any API/endpoint using which I can get activation_code & activation_barcode for a user if it already exists? So that I can show these codes to the user whenever he is looking for registration.

I hope you will help me out. Looking forward to hearing from you.

First call /preauth to see if the user exists. Use the result from/preauth to determine your next step (i.e. if it returns enroll, then call /enroll).