Skip to content

Commit

Permalink
Merge pull request #11 from johnduprey/dev
Browse files Browse the repository at this point in the history
Auth API + Docs
  • Loading branch information
JohnDuprey authored Dec 9, 2022
2 parents a2827fb + b1132ba commit 2b4c9d3
Show file tree
Hide file tree
Showing 18 changed files with 1,268 additions and 9 deletions.
73 changes: 73 additions & 0 deletions Docs/Get-DuoAuthEnrollmentStatus.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
---
external help file: DuoSecurity-help.xml
Module Name: DuoSecurity
online version: https://duo.com/docs/authapi#/enroll_status
schema: 2.0.0
---

# Get-DuoAuthEnrollmentStatus

## SYNOPSIS
Duo Auth Enrollment Status

## SYNTAX

```
Get-DuoAuthEnrollmentStatus [-UserId] <String> [-ActivationCode] <String> [<CommonParameters>]
```

## DESCRIPTION
Check whether a user has completed enrollment.

## EXAMPLES

### EXAMPLE 1
```
Get-DuoAuthEnrollmentStatus -UserId SOMEUSERID -ActivationCode SOMEACTIVATIONCODE
```

## PARAMETERS

### -UserId
ID of the user.

```yaml
Type: String
Parameter Sets: (All)
Aliases: user_id

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
```
### -ActivationCode
Activation code, as returned from /enroll.
```yaml
Type: String
Parameter Sets: (All)
Aliases: activation_code

Required: True
Position: 2
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
```
### CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
## INPUTS
## OUTPUTS
## NOTES
## RELATED LINKS
[https://duo.com/docs/authapi#/enroll_status](https://duo.com/docs/authapi#/enroll_status)
58 changes: 58 additions & 0 deletions Docs/Get-DuoAuthLogo.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
external help file: DuoSecurity-help.xml
Module Name: DuoSecurity
online version: https://duo.com/docs/authapi#/logo
schema: 2.0.0
---

# Get-DuoAuthLogo

## SYNOPSIS
Duo Auth Logo

## SYNTAX

```
Get-DuoAuthLogo [-FilePath] <String> [<CommonParameters>]
```

## DESCRIPTION
The /logo endpoint provides a programmatic way to retrieve your stored logo.

## EXAMPLES

### EXAMPLE 1
```
Get-DuoAuthLogo -FilePath ./logo.png
```

## PARAMETERS

### -FilePath
Where to save the logo

```yaml
Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```
### CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
## INPUTS
## OUTPUTS
## NOTES
## RELATED LINKS
[https://duo.com/docs/authapi#/logo](https://duo.com/docs/authapi#/logo)
59 changes: 59 additions & 0 deletions Docs/Get-DuoAuthStatus.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
external help file: DuoSecurity-help.xml
Module Name: DuoSecurity
online version: https://duo.com/docs/authapi#/auth_status
schema: 2.0.0
---

# Get-DuoAuthStatus

## SYNOPSIS
Duo API Auth Status

## SYNTAX

```
Get-DuoAuthStatus [-TxId] <String> [<CommonParameters>]
```

## DESCRIPTION
The /auth_status endpoint "long-polls" for the next status update from the authentication process for a given transaction.
That is to say, if no status update is available at the time the request is sent, it will wait until there is an update before returning a response.

## EXAMPLES

### EXAMPLE 1
```
Get-DuoAuthStatus -TxId 66cc8d20-fdfa-41bc-8b74-1a3b095d55f7
```

## PARAMETERS

### -TxId
The transaction ID of the authentication attempt, as returned by the /auth endpoint.

```yaml
Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False
```
### CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
## INPUTS
## OUTPUTS
## NOTES
## RELATED LINKS
[https://duo.com/docs/authapi#/auth_status](https://duo.com/docs/authapi#/auth_status)
75 changes: 75 additions & 0 deletions Docs/New-DuoAuthEnrollment.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
---
external help file: DuoSecurity-help.xml
Module Name: DuoSecurity
online version: https://duo.com/docs/adminapi#add-administrative-unit
schema: 2.0.0
---

# New-DuoAuthEnrollment

## SYNOPSIS
Duo Auth Enrollment

## SYNTAX

```
New-DuoAuthEnrollment [[-Username] <String>] [[-ValidSecs] <Int32>] [<CommonParameters>]
```

## DESCRIPTION
The /enroll endpoint provides a programmatic way to enroll new users with Duo two-factor authentication.
It creates the user in Duo and returns a code (as a QR code) that Duo Mobile can scan with its built-in camera.
Scanning the QR code adds the user's account to the app so that they receive and respond to Duo Push login requests.

## EXAMPLES

### EXAMPLE 1
```
New-DuoAuthEnrollment
```

## PARAMETERS

### -Username
Username for the created user.
If not given, a random username will be assigned and returned.

```yaml
Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```
### -ValidSecs
Seconds for which the activation code will remain valid.
Default: 86400 (one day).
```yaml
Type: Int32
Parameter Sets: (All)
Aliases:

Required: False
Position: 2
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False
```
### CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
## INPUTS
## OUTPUTS
## NOTES
General notes
## RELATED LINKS
Loading

0 comments on commit 2b4c9d3

Please sign in to comment.