본문으로 건너뛰기
사용자

Cernium/ACLGroup/api(r7판)

편집 시각·0
보기RAW역사
[주의!] 문서의 이전 버전(에 수정)을 보고 있습니다. 최신 버전으로 이동
↑ 상위 문서: 사용자:Cernium/ACLGroup

GET /api/v0/aclgroup
PUT /api/v0/aclgroup
DELETE /api/v0/aclgroup

https://theseed.io/thread/YummyGiganticBrashDistribution
#

https://theseed.io/internal/admin/thread/YummyGiganticBrashDistribution/hide

1. 기본[편집]

import requests
import json

headers = {
    'Authorization': 'Bearer API_TOKEN_HERE'
}

2. 목록[편집]

3. 추가[편집]

data = {
    'group': '로그인 허용 차단', #ACLGroup 이름
    'username': 'Cernium', #사용자 이름; mode=ip이면 'ip'로
    'note': 'api test', #사유
    'expire': '20', #추가할 시간(초)
    'mode': 'username' #ip OR username
}
response = requests.post('https://theseed.io/api/v0/aclgroup', headers=headers, data=data)

4. 제거[편집]

data = {
    'group': '경고-테스트', #ACLGroup 이름
    'id': '14559', #차단 id
    'note': 'api test' #사유
}
response = requests.delete('https://theseed.io/api/v0/aclgroup', headers=headers, data=data)