Skip to content

Missing field in CreateFederatedIdentityProviderResponse #5856

@aaguilartablada

Description

@aaguilartablada

Description

ServiceAccount API responds a JSON that contains "id" field, but this field is missing in CreateFederatedIdentityProviderResponse struct and produce a JSON marshal error.

Steps to reproduce

item := "aud"
operator := "equals"
value := "someaud"

payload := serviceaccountAPI.CreateFederatedIdentityProviderPayload{
	Name:   "test",
	Issuer: "https://vstoken.dev.azure.com/xxxxxxxxx",
	Assertions: []serviceaccountAPI.CreateFederatedIdentityProviderPayloadAssertionsInner{
		{
			Item:     &item,
			Operator: &operator,
			Value:    &value,
		},
	},
}

_, err = client.DefaultAPI.CreateFederatedIdentityProvider(context.Background(), projectId, saEmail).CreateFederatedIdentityProviderPayload(payload).Execute()

if err != nil {
	println(err.Error())
}

Current behavior

The code above will print the next line:

json: unknown field "id", status code 201, Body: {"id":"f464d73f-fb1b-467b-bb11-80e0286fe51f","name":"test","issuer":"https://vstoken.dev.azure.com/xxxxxxxxx","assertions":[{"item":"aud","operator":"equals","value":"someaud"}],"createdAt":"2026-03-11T09:39:12.080255397Z","updatedAt":"2026-03-11T09:39:12.080255467Z"}

Expected behavior

I expect an error does NOT occur, as federation is created correctly. It seems to be just a SDK bug.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions