Skip to content

Java Implmentation #101

Closed Answered by diegoocampoh
Kachopsticks asked this question in Q&A
May 23, 2023 · 5 comments · 6 replies
Discussion options

You must be logged in to vote

Hi @Kachopsticks, 1time 2.0.1 is released. If using maven, do:

<dependency>
    <groupId>com.atlassian</groupId>
    <artifactId>onetime</artifactId>
    <version>2.0.1</version>
</dependency>

And then see the full Java example:

package com.mycompany.app;

import com.atlassian.onetime.core.TOTP;
import com.atlassian.onetime.core.TOTPGenerator;
import com.atlassian.onetime.model.TOTPSecret;
import com.atlassian.onetime.service.DefaultTOTPService;
import com.atlassian.onetime.service.TOTPVerificationResult;

public class App {
    public static void main(String[] args) {

        //Client generating a TOTP given a secret
        TOTPSecret secret = TOTPSecret.Companion.fromBase32EncodedString(

Replies: 5 comments 6 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
5 replies
@diegoocampoh
Comment options

@Kachopsticks
Comment options

@diegoocampoh
Comment options

@Kachopsticks
Comment options

@diegoocampoh
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by diegoocampoh
Comment options

You must be logged in to vote
1 reply
@diegoocampoh
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants