Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
docs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Thomas
docs
Commits
86eb63bc
Commit
86eb63bc
authored
Oct 05, 2018
by
Eugen Rochko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add domain blocks API
parent
c9c516ee
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
51 additions
and
3 deletions
+51
-3
domain-blocks.md
content/en/api/rest/domain-blocks.md
+50
-2
api_method_info.html
layouts/shortcodes/api_method_info.html
+1
-1
No files found.
content/en/api/rest/domain-blocks.md
View file @
86eb63bc
---
title
:
Domain blocks
API
title
:
Domain blocks
menu
:
docs
:
parent
:
api
parent
:
rest-
api
weight
:
10
---
## GET /api/v1/domain_blocks
Domains the user has blocked.
Returns array of string.
### Resource information
{{
<
api
_method_info
auth=
"Yes"
user=
"Yes"
scope=
"read read:blocks follow"
version=
"0.0.0"
>
}}
### Parameters
|Name|Description|Required|Default|
|----|-----------|:------:|:-----:|
|
`limit`
| Maximum number of results | Optional | 40 |
### Pagination
{{
<
api
_pagination
>
}}
## POST /api/v1/domain_blocks
Block a domain to hide all public posts from it, all notifications from it, and remove all followers from it.
### Resource information
{{
<
api
_method_info
auth=
"Yes"
user=
"Yes"
scope=
"write write:blocks follow"
version=
"0.0.0"
>
}}
### Parameters
|Name|Description|Required|Default|
|----|-----------|:------:|:-----:|
|
`domain`
| Domain to block| Required ||
## DELETE /api/v1/domain_blocks
Remove a domain block.
### Resource information
{{
<
api
_method_info
auth=
"Yes"
user=
"Yes"
scope=
"write write:blocks follow"
version=
"0.0.0"
>
}}
### Parameters
|Name|Description|Required|Default|
|----|-----------|:------:|:-----:|
|
`domain`
| Domain to block| Required ||
layouts/shortcodes/api_method_info.html
View file @
86eb63bc
...
...
@@ -18,7 +18,7 @@
{{ with .Get "scope" }}
<tr>
<th
style=
"text-align: left"
>
Scope
</th>
<td>
<code>
{{.}}
</code>
</td>
<td>
{{range split . " "}}
<code>
{{ . }}
</code>
{{ end }}
</td>
</tr>
{{ end }}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment