How do I call this from in swift using LiveKit's M...
# ask-ai
s
How do I call this from in swift using LiveKit's Mobile SDK?
Copy code
@ctx.room.local_participant.register_rpc_method("toggle_audio")
    async def on_toggle_audio(data: rtc.RpcInvocationData) -> None:
        session.input.set_audio_enabled(not session.input.audio_enabled)
        session.output.set_audio_enabled(not session.output.audio_enabled)
t
Thanks for reaching out, Antonio. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
I don't have the answer you're looking for. You could also try asking your question: • in one of the other Slack channels or • to https://deepwiki.com/livekit/livekit_composite which is trained on all LiveKit source code If you find the answer, please post it here to help others!