semvec/pypi-packages huggingface dataset:
golang-code-anal 2022.8.16.0
ApacheCN Golang 源码分析
Requires Python: >=3.6

# ApacheCN Golang 源码分析

> 协议：[CC BY-NC-SA 4.0](http://creativecommons.org/licenses/by-nc-sa/4.0/)
> 
> 新时代需要新道德。——《三体》

* [在线阅读](https://goca.apachecn.org)
* [在线阅读（Gitee）](https://apachecn.gitee.io/doc-template/)
* [ApacheCN 学习资源](http://docs.apachecn.org/)

## 贡献指南

本项目需要校对，欢迎大家提交 Pull Request。

> 请您勇敢地去翻译和改进翻译。虽然我们追求卓越，但我们并不要求您做到十全十美，因此请不要担心因为翻译上犯错——在大部分情况下，我们的服务器已经记录所有的翻译，因此您不必担心会因为您的失误遭到无法挽回的破坏。（改编自维基百科）

## 联系方式

### 负责人

* [飞龙](https://github.com/wizardforcel): 562826179

### 其他

*   在我们的 [apachecn/golang-code-anal](https://github.com/apachecn/golang-code-anal) github 上提 issue.
*   发邮件到 Email: `apachecn@163.com`.
*   在我们的 [组织学习交流群](https://www.apachecn.org/#/docs/join) 中联系群主/管理员即可.

## 下载

### Docker

```
docker pull apachecn0/golang-code-anal
docker run -tid -p <port>:80 apachecn0/golang-code-anal
# 访问 http://localhost:{port} 查看文档
```

### PYPI

```
pip install golang-code-anal
golang-code-anal <port>
# 访问 http://localhost:{port} 查看文档
```

### NPM

```
npm install -g golang-code-anal
golang-code-anal <port>
# 访问 http://localhost:{port} 查看文档
```

## 其它协议

霞鹜文楷采用 [SIL 开放字体协议 1.1](https://github.com/lxgw/LxgwWenKai/blob/main/SIL_Open_Font_License_1.1.txt)。

## 赞助我们

![](http://data.apachecn.org/img/about/donate.jpg)
aqara-capi 1.2.0
Aqara Cloud API SDK


# Aqara Cloud API

[![CodeFactor](https://www.codefactor.io/repository/github/moff4/aqara_capi/badge)](https://www.codefactor.io/repository/github/moff4/aqara_capi)

### Python SDK for Aqara Cloud API

_(Functionality is not full, but already has core for futher upgrades)_

### Install

```bash
pip install aqara_capi
```

### Example of usage

```python

from aqara_capi import CloudApiClient, Locality

# create client
client = CloudApiClient(
    app_id=APP_ID,  # your params from https://developer.aqara.com/console
    app_key=APP_KEY,
    key_id=KEY_ID,
    locality=Locality.RU,  # for cloud domain
)

# set access and refresh tokens
client.set_tokens(access_token='...', refresh_token='...')

# or generate them
client.get_auth_code(
    account='my@example.com',
    account_type=0,
    access_token_validity='7d',
)
client.get_access_token(
    auth_code='secret code from ur email',
    account='my@example.com',
    account_type=0,
)


# print your devices
response = client.query_device_info()
print(response.result)

# print device attributes
response = client.query_resource_info(
    model='lumi.light....',
)
print(response.result)

# trigger some action (for example turn on light)
client.write_resource_device(
    subject_id='lumi...',
    resource_id='4.1.85',
    value='1',
)

```