---
title: "success(with:)"
framework: intents
role: symbol
role_heading: Type Method
path: "intents/invisualcodetyperesolutionresult/success(with:)"
---

# success(with:)

Creates an object whose resolution involves the successful matching of the specified value.

## Declaration

```swift
class func success(with resolvedVisualCodeType: INVisualCodeType) -> Self
```

## Parameters

- `resolvedVisualCodeType`: The value that resolves the requested value of the intent.

## Return Value

Return Value A new INVisualCodeTypeResolutionResult object.

## Discussion

Discussion Use this method to create a result object when you’re able to provide a visual code of the specified type.

## See Also

### Creating a Resolution Result Object

- [confirmationRequired(with:)](intents/invisualcodetyperesolutionresult/confirmationrequired(with:).md)
