more endpoints
This commit is contained in:
@ -158,7 +158,7 @@ export default function Pricing() {
|
|||||||
</pre>
|
</pre>
|
||||||
|
|
||||||
<h2>Methods</h2>
|
<h2>Methods</h2>
|
||||||
|
<Methods>
|
||||||
<Method method="user.info" label="Get current user">
|
<Method method="user.info" label="Get current user">
|
||||||
<Description>
|
<Description>
|
||||||
This method returns the information for currently logged in user.
|
This method returns the information for currently logged in user.
|
||||||
@ -170,9 +170,9 @@ export default function Pricing() {
|
|||||||
|
|
||||||
<Method method="user.s3Upload" label="Get S3 upload credentials">
|
<Method method="user.s3Upload" label="Get S3 upload credentials">
|
||||||
<Description>
|
<Description>
|
||||||
You can upload small files and images as part of your documents. All
|
You can upload small files and images as part of your documents.
|
||||||
files are stored using Amazon S3. Instead of uploading files to
|
All files are stored using Amazon S3. Instead of uploading files
|
||||||
Outline, you need to upload them directly to S3 with special
|
to Outline, you need to upload them directly to S3 with special
|
||||||
credentials which can be obtained through this endpoint.
|
credentials which can be obtained through this endpoint.
|
||||||
</Description>
|
</Description>
|
||||||
<Arguments>
|
<Arguments>
|
||||||
@ -225,19 +225,43 @@ export default function Pricing() {
|
|||||||
</Arguments>
|
</Arguments>
|
||||||
</Method>
|
</Method>
|
||||||
|
|
||||||
|
<Method method="collections.update" label="Update a collection">
|
||||||
|
<Description>
|
||||||
|
This method allows you to modify already created document.
|
||||||
|
</Description>
|
||||||
|
<Arguments>
|
||||||
|
<Argument id="id" description="Collection ID" required />
|
||||||
|
<Argument id="name" description="Name for the collection" />
|
||||||
|
<Argument
|
||||||
|
id="color"
|
||||||
|
description="Collection color in hex form (e.g. #E1E1E1)"
|
||||||
|
/>
|
||||||
|
</Arguments>
|
||||||
|
</Method>
|
||||||
|
|
||||||
|
<Method method="collections.delete" label="Delete a collection">
|
||||||
|
<Description>
|
||||||
|
Delete a collection and all of its documents. This action can't be
|
||||||
|
undone so please be careful.
|
||||||
|
</Description>
|
||||||
|
<Arguments>
|
||||||
|
<Argument id="id" description="Collection ID" required />
|
||||||
|
</Arguments>
|
||||||
|
</Method>
|
||||||
|
|
||||||
<Method method="documents.info" label="Get a document">
|
<Method method="documents.info" label="Get a document">
|
||||||
<Description>
|
<Description>
|
||||||
<p>
|
<p>
|
||||||
This method returns information for a document with a specific ID.
|
This method returns information for a document with a specific
|
||||||
Following identifiers are allowed:
|
ID. Following identifiers are allowed:
|
||||||
</p>
|
</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>
|
<li>
|
||||||
UUID - <code>id</code> field of the document
|
UUID - <code>id</code> field of the document
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
URI identifier - Human readable identifier used in Outline URLs
|
URI identifier - Human readable identifier used in Outline
|
||||||
(e.g. <code>outline-api-i48ZEZc5zjXndcP</code>)
|
URLs (e.g. <code>outline-api-i48ZEZc5zjXndcP</code>)
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</Description>
|
</Description>
|
||||||
@ -321,8 +345,8 @@ export default function Pricing() {
|
|||||||
<Description>
|
<Description>
|
||||||
Move a document into a new location inside the collection. This is
|
Move a document into a new location inside the collection. This is
|
||||||
easily done by defining the parent document ID and optional index.
|
easily done by defining the parent document ID and optional index.
|
||||||
If no parent document is provided, the document will be moved to the
|
If no parent document is provided, the document will be moved to
|
||||||
collection root.
|
the collection root.
|
||||||
</Description>
|
</Description>
|
||||||
<Arguments>
|
<Arguments>
|
||||||
<Argument
|
<Argument
|
||||||
@ -421,13 +445,36 @@ export default function Pricing() {
|
|||||||
</Description>
|
</Description>
|
||||||
<Arguments pagination />
|
<Arguments pagination />
|
||||||
</Method>
|
</Method>
|
||||||
|
</Methods>
|
||||||
</Container>
|
</Container>
|
||||||
</Grid>
|
</Grid>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const MethodList = styled.ul`
|
||||||
|
margin-bottom: 80px;
|
||||||
|
`;
|
||||||
|
|
||||||
|
const Methods = (props: { children: React.Element<*> }) => {
|
||||||
|
const children = React.Children.toArray(props.children);
|
||||||
|
const methods = children.map(child => child.props.method);
|
||||||
|
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<MethodList>
|
||||||
|
{methods.map(method => (
|
||||||
|
<li key={method}>
|
||||||
|
<a href={`#${method}`}>{method}</a>
|
||||||
|
</li>
|
||||||
|
))}
|
||||||
|
</MethodList>
|
||||||
|
{children}
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
const MethodContainer = styled.div`
|
const MethodContainer = styled.div`
|
||||||
margin-bottom: 40px;
|
margin-bottom: 80px;
|
||||||
`;
|
`;
|
||||||
|
|
||||||
const Request = styled.h4`
|
const Request = styled.h4`
|
||||||
@ -447,7 +494,7 @@ const Method = (props: MethodProps) => {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<MethodContainer>
|
<MethodContainer>
|
||||||
<h3>
|
<h3 id={props.method}>
|
||||||
<code>{props.method}</code> - {props.label}
|
<code>{props.method}</code> - {props.label}
|
||||||
</h3>
|
</h3>
|
||||||
<div>{description}</div>
|
<div>{description}</div>
|
||||||
|
Reference in New Issue
Block a user