项目介绍

AgoraIO/Agora-Miniapp-Tutorial 是一个托管在 GitHub 上的开源项目,主要使用 JavaScript 编写,目前获得 115 个 Star、44 次 Fork。

仓库全名
AgoraIO/Agora-Miniapp-Tutorial
Star 数
115
Fork 数
44
未关闭 Issue
2

README 摘要

Agora Miniapp Tutorial 其他语言版本:简体中文 Introduction Built upon the Agora Miniapp SDK, the Agora Miniapp Sample App is an open-source demo that integrates video chat and live broadcast into your Wechat Mini Application. With this sample app, you can: Integrate the Agora Miniapp SDK Join a channel Push your local stream to the channel Subscribe to remote streams in the same channel Leave a channel Preparing the Developer…

完整内容见 GitHub 原始 README 或本页 。

常见问题

Agora-Miniapp-Tutorial 用什么语言开发?

主要使用 JavaScript 编写,目前有 115 个 Star。

如何获取 Agora-Miniapp-Tutorial 的源码?

可以直接克隆仓库:git clone https://github.com/AgoraIO/Agora-Miniapp-Tutorial.git,默认分支为 master;安装与运行步骤见仓库 README。

Agora-Miniapp-Tutorial 最近还在维护吗?

仓库最近一次更新为 2024年4月28日,当前有 2 个未关闭 Issue;Star 数为 115,可作为社区活跃度的参考。

关于

Hello world for Agora SDK running in https://en.wikipedia.org/wiki/WeChat#WeChat_Mini_Program

描述取自 GitHub 官方 API,中文内容由 GitRead 中文社区 编辑团队整理。

简要分析

热度分
256
价值分
87
活跃状态
活跃

语言占比

JavaScript

README

Agora Miniapp Tutorial

其他语言版本:简体中文

Introduction

Built upon the Agora Miniapp SDK, the Agora Miniapp Sample App is an open-source demo that integrates video chat and live broadcast into your Wechat Mini Application.

With this sample app, you can:

  • Integrate the Agora Miniapp SDK
  • Join a channel
  • Push your local stream to the channel
  • Subscribe to remote streams in the same channel
  • Leave a channel

Preparing the Developer Environment

  1. Ensure that you have installed the WeChat Developer Tool.
  2. Ensure that you have a wechat OpenPlatform account that supports live-pusher and live-player. Only certified corporate accounts in certain industry have access to these two components. For details, click here .
  3. Ensure that you have granted access to the following domains in your OpenPlatform account:

Running the App

  1. Create a developer account at Agora.io, create a new project and obtain an App ID, and enable the App Certificate.

  2. Download this project.

  3. Fill in the App ID in config.js in the utils folder of this project:

     const APPID = 'abcdefg'
    
  4. Contact [email protected] to abtain the Agora Miniapp SDK, and rename the SDK to “agora-miniapp-sdk.js”.

  5. Save the “agora-miniapp-sdk.js” under the lib folder of this project.

  6. Start the WeChat Developer Tool and import this project.

  7. Enter a channel name and join a channel. Invite your friend to join in the same channel and you will be able to see each other.

About the Token/Dynamic Key

If you have enabled the App Certificate, you will need to generate the Token/Dynamic Key at the server for authentication purposes. Use it in the following method:

	//...
	client.join(<your key/access token here>, channel, uid, () => {
	//...

See Token or Dynamic Key for generating the Token or Key at the server.

Feedback

If you have any problems or suggestions regarding the sample projects, feel free to file an issue.

  • Check our FAQ to see if your issue has been recorded.
  • Dive into Agora SDK Samples to see more tutorials
  • Take a look at Agora Use Case for more complicated real use case
  • Repositories managed by developer communities can be found at Agora Community
  • If you encounter problems during integration, feel free to ask questions in Stack Overflow

License

The sample projects are under the MIT license.

评论

暂无评论