Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

146
Visualizações
How to delete a conversation participant user by its identity

I add users to conversations through API REST. For example I do:

await client.conversations
    .services(TWILIO_CHAT_SERVICE_SID)
    .conversations(conversationSid)
    .participants.create({ identity: myIdentity });

Consider that I need to delete users from conversation only through API REST. I found out here how to remove them by its sid. Is there any way to remove them by its identity? I need to do so because I don't keep trace of participant's sid into my DB. If I have to then I will.

So how would you face this problem?

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

I think you need the SID. Thankfully when you create a participant in the conversation, the API responds with the SID.

const participant = await client.conversations
    .services(TWILIO_CHAT_SERVICE_SID)
    .conversations(conversationSid)
    .participants.create({ identity: myIdentity });

console.log(participant.sid);

So, when you create the participant, store their SID. Then when you need to update or delete them, you can fetch their SID from your own database.

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda