Skip to main content

ConnectedLensSessionOptions.SessionCreationType

Enum

Type of the created Connected Lens session.

  • Available on all platforms
Platform details: Snapchat, SPECS, Camera Kit Web, Camera Kit Mobile fully supported.

Platform details

  • Snapchat — Fully supported.

  • SPECS — Fully supported.

  • Camera Kit Web — Fully supported.

  • Camera Kit Mobile — Fully supported.

Since Lens Scripting v148

Index

Example

function onSessionCreated(session, sessionCreationType) {
if (sessionCreationType == ConnectedLensSessionOptions.SessionCreationType.MultiplayerReceiver) {
print("Session was joined via invite");
}
else if (sessionCreationType == ConnectedLensSessionOptions.SessionCreationType.New) {
print("New session was created");
}
}

Enumeration Members

MultiplayerReceiver

MultiplayerReceiver: number

Session was joined via invite.

Since

Lens Scripting Version 148


New

New: number

New Session was created.

Since

Lens Scripting Version 148


NewSoloMode

NewSoloMode: number

A Connected Lens session with only the current user.

Since

Lens Scripting Version 148