microsoftgraph / microsoftgraph/msgraph-sdk-python

IdentitySet class does not have 'phone' property

Abierto
#1,424 1 comentario 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

dependency:metadata type:bug
Lenguaje dominante
Python
Estrellas
630
Forks
96
Merge medio
15 h 20 min
PR fusionados (30 d)
3

Descripción

Describe the bug

When trying to make a phone call, I specify the IdentitySet of the Target user like this:

    targets = [
        InvitationParticipantInfo(
            identity = IdentitySet(
                phone = Identity(
                    id = "+mynumber"
                )
            )
        )
    ]

However I get the following error "IdentitySet.init() got an unexpected keyword argument 'phone'" stating that this parameter is not available for the IdentitySet class.
This works when calling from the rest API

Expected behavior

Parameter should be present in the class, just like the user parameter for calling an teams userid

How to reproduce
target_identity = IdentitySet(phone=Identity(id=graph_p.phone_number))
target = InvitationParticipantInfo(
    identity = target_identity
)
request_body = Call(
    callback_uri = "myballback",
    tenant_id = tenant_id,
    source = ParticipantInfo(
        identity = IdentitySet(
            application = Identity(
                id = bot_instance_id
            )
        )
    ),
    targets = [target],
    requested_modalities = [Modality.Audio],
    media_config = ServiceHostedMediaConfig(
        pre_fetch_media = []
    )
)
SDK Version

No response

Latest version known to work for scenario above?

No response

Known Workarounds

Use IdentitySet additional_data parameter in order to inject the phone parameter to the body

Debug output
Click to expand log ```
</details>


### Configuration

_No response_

### Other information

_No response_

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Línea de trabajo

Comienza en el punto de entrada del modelo IdentitySet y reproduce la construcción IdentitySet(phone=Identity(...)) del issue. Compara los parámetros del constructor admitidos con la forma de la REST API y verifica que un destino phone pueda representarse en el cuerpo de la solicitud generado sin usar additional_data.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
python
Área
api
Tipo de issue
Error
Dificultad
3/5
Tiempo estimado
1-2 días
Estado de actividad
Tranquilo
Claridad
Bastante claro
Aptitud para principiantes
52/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.