We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I can't find any informations about error handling, for instance i want to check for write_failed_due_to_invalid_input from https://github.com/openfga/go-sdk/blob/v0.7.1/docs/ErrorCode.md
write_failed_due_to_invalid_input
Please provide an example
Current try:
if _, err = service.fgaClient. Write(ctx). Body(openfgaclient.ClientWriteRequest{ Writes: writes, Deletes: deletes, }). Execute(); err != nil { var fgaErr *openfga.FgaApiError if errors.As(err, &fgaErr) { switch fgaErr.ResponseCode() { case string(openfga.ERRORCODE_WRITE_FAILED_DUE_TO_INVALID_INPUT): return nil, service.statusError.InvalidArgumentError(fgaErr.Error()).Err() } } statusErr := service.statusError.InternalError() service.logger.Error(fmt.Sprintf("openfga client write: %s", err), logging.ExtractFields(ctx)...) return nil, statusErr.Err() }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I can't find any informations about error handling, for instance i want to check for
write_failed_due_to_invalid_input
from https://github.com/openfga/go-sdk/blob/v0.7.1/docs/ErrorCode.mdPlease provide an example
Current try:
The text was updated successfully, but these errors were encountered: