Skip to content

Apps API is not properly represented with openapi codegen #493

Open
@duytiennguyen-okta

Description

@duytiennguyen-okta

Describe the bug?

Discriminator property is coming as "null" for some type of applications due to which returned response is not mapped to any polymorphic type. For ex-
GET /api/v1/apps?filter=name eq "active_directory"
Response:

[
    {
        "id": "0oa12ensf1P3tOPdF7k6",
        "orn": "orn:okta:idp:00o12eniiOtpqtsAZ7k6:apps:active_directory:0oa12ensf1P3tOPdF7k6",
        "name": "active_directory",
        "label": "iwa.dc",
        "status": "ACTIVE",
        "lastUpdated": "2024-11-05T20:58:46.000Z",
        "created": "2024-09-18T17:29:34.000Z",
        "accessibility": {
            "selfService": false,
            "errorRedirectUrl": null,
            "loginRedirectUrl": null
        },
        "visibility": {
            "autoSubmitToolbar": false,
            "hide": {
                "iOS": false,
                "web": false
            },
            "appLinks": {}
        },
        "features": [
            "IMPORT_PROFILE_UPDATES",
            "PROFILE_MASTERING",
            "OUTBOUND_DEL_AUTH",
            "IMPORT_USER_SCHEMA",
            "IMPORT_NEW_USERS"
        ],
        "signOnMode": null,
        "credentials": {
            "userNameTemplate": {
                "template": "substringBefore(user.login, \"@\") + \"@\" + target_app.namingContext",
                "type": "CUSTOM",
                "pushStatus": "NOT_CONFIGURED"
            },
            "signing": {}
        },
        "settings": {
            "app": {},
            "notifications": {
                "vpn": {
                    "network": {
                        "connection": "DISABLED"
                    },
                    "message": null,
                    "helpUrl": null
                }
            },
            "manualProvisioning": false,
            "implicitAssignment": false,
            "emOptInStatus": "NONE"
        },
    }
]

What is expected to happen?

Map to ListApplications200ResponseInner

What is the actual behavior?

Unable to map to ListApplications200ResponseInner because signOnMode is null

Reproduction Steps?

This is an issue with codegen

Additional Information?

No response

Golang Version

1.21

SDK Version

v5

OS version

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingstale

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions