メインコンテンツにジャンプ
@capgo/capacitor-ストリームコール コミュニケーション オープンソース

ストリームコール Capacitor プラグイン

ストリーム SDK を使用してリアルタイムコミュニケーションを実現するビデオコールとライブストリーミングを統合

インストール

bun add @capgo/capacitor-stream-call bunx cap sync
npm、pnpm、またはyarn
  • npm install @capgo/capacitor-stream-call
  • pnpm add @capgo/capacitor-stream-call
  • yarn add @capgo/capacitor-stream-call

ガイド

How to use Streamcall in Capacitor

Using @capgo/capacitor-stream-call

Streamcallを使用する https://getstream.io/ SDKを使用してCapacitorのコールを実装する

インストール

bun add @capgo/capacitor-stream-call
bunx cap sync

bunx cap sync プラグインのネイティブcodeをプロジェクトにコピーします。プラグインのアップグレード後は再度実行してください。

インポート

import { StreamCall } from '@capgo/capacitor-stream-call';

APIの概要

メソッド Description
login __CAPGO_KEEP_0__
logout Stream Video サービスからログアウト.
call 別のユーザーに電話をかけます.
endCall 現在の通話を終了.
joinCall 既存の通話に参加.
setMicrophoneEnabled マイクを有効または無効.
setCameraEnabled カメラを有効または無効.
enableBluetooth Bluetoothオーディオを有効.
acceptCall 着信を承認.
rejectCall 着信を拒否.
isCameraEnabled カメラが有効かどうかを確認.
getCallStatus 現在の通話の状態を取得.
getRingingCall 現在の着信通話を取得.
toggleViews 動画レイアウトをサイクルする。
setSpeaker スピーカーフォンをセットする。
switchCamera カメラを切り替える。
getCallInfo 現在の通話の詳細情報を取得する。これには、通話者の詳細も含まれる。
setDynamicStreamVideoApikey 静的のStream Video APIキーを上書きする動的Stream Video APIキーをセットする。
getDynamicStreamVideoApikey 現在の動的Stream Video APIキーを取得する。
getCurrentUser 現在のユーザーの情報を取得する。

例

login()

コンテキスト: Bug bountyプログラムページ。役割: セクションまたはページヘッダー。見られる場所: bug-bounty.astroページ。メッセージキー `bug_bounty_supabase_examples_title` (Bug Bounty Supabase Examples Title)。

import { StreamCall } from '@capgo/capacitor-stream-call';

await StreamCall.login({
  token: 'your-token',
  userId: 'user-123',
  name: 'John Doe',
  apiKey: 'your-api-key'
});

logout()

Stream Videoサービスにログインする。

import { StreamCall } from '@capgo/capacitor-stream-call';

await StreamCall.logout();

call()

Stream Videoサービスからログアウトする。

import { StreamCall } from '@capgo/capacitor-stream-call';

await StreamCall.call({
  userId: 'user-456',
  type: 'video',
  ring: true
});

endCall()

他のユーザーに電話をかける。

import { StreamCall } from '@capgo/capacitor-stream-call';

await StreamCall.endCall();

joinCall()

参加している会議に参加する。

import { StreamCall } from '@capgo/capacitor-stream-call';

await StreamCall.joinCall({ callId: 'call001', callType: 'default' });

setMicrophoneEnabled()

マイクを有効または無効にする。

import { StreamCall } from '@capgo/capacitor-stream-call';

await StreamCall.setMicrophoneEnabled({ enabled: false });

上の表には、20の基本メソッドがリストされています。リスナーとバージョンヘルパー、各メソッドの完全な契約書は、__CAPGO_KEEP_0__ リポジトリに記載されています。 GitHub リポジトリ.

ハンドルを返します。画面がアンマウントされたとき、またはリスナーをすべてクリアするときに呼び出します。

addListener フルリファレンス handle.remove() ドキュメント StreamCall.removeAllListeners() __CAPGO_KEEP_0__ リファレンス

ドキュメント

Capacitorから続けて@capgo/capacitor-stream-callを使用

Capacitor-stream-callを使用している場合 Using @capgo/capacitor-stream-call Capacitor-stream-callを使用して Capacitor-stream-callの実装詳細については@capgo/capacitor-stream-callを参照 @capgo/capacitor-ストリームコールの実装詳細 __CAPGO_KEEP_0__ プラグインディレクトリ Capacitor-Streamcallの実装詳細については、Getting Startedを参照してください。 Capgo プラグイン Capgo プラグインの実装詳細についてはCapgo Plugins by __CAPGO_KEEP_1__を参照 Capacitor Capgo for Capacitor の実装詳細については、Capgo によって提供されるプラグインを参照してください。 プラグインの追加または更新 プラグインの追加または更新の実装詳細について

FAQ

Streamcall プラグイン FAQ

Streamcall プラグインを Capacitor アプリにどのようにインストールしますか?

Run "bun add @capgo/capacitor-stream-call" (or "npm install @capgo/capacitor-stream-call"), then run "bunx cap sync" so the iOS and Android projects pick up the native code. Import it from "@capgo/capacitor-stream-call" in your app code.

@capgo/capacitor-stream-callは、React、Vue、Angularとどのように動作するか?

はい。Streamcall は Capacitor パッケージなので、Ionic、React、Vue、Angular、Svelte、または単純な JavaScript など、Capacitor 内で実行される任意の Web フレームワークと互換性があります。

どの Capacitor バージョンが @capgo/capacitor-stream-call をサポートしますか?

Capgo plugins follow Capacitor's major version: use the plugin major version that matches your Capacitor major version (for example plugin v8 with Capacitor 8). The compatibility table in the GitHub README lists the maintained versions.

は @capgo/capacitor-stream-call が無料でオープンソースですか?

Yes. The source code is public on GitHub at https://github.com/Cap-go/capacitor-streamcall/ and the package is free to install from npm. Bug reports and pull requests are welcome.

Streamcall を使用する code を App Store のレビューなしでアップデートできますか?

プラグインをインストールまたはアップグレードすると、native code が変更されるため、ストアビルドが必要になります。 その後、JavaScript、HTML、CSS の変更がプラグインを呼び出すと Capgo のライブアップデートで即時配信できます。

アプリレビューを待たずにStreamcallの変更を配信する

Once the plugin is in your store build, Capgo live updates push your JavaScript, HTML and CSS changes to users in minutes.

Start with Capgo