### GET /v2/channels Source: https://dev.are.na/documentation/channels Retrieves a list of published channels. Supports pagination. ```APIDOC ## GET /v2/channels ### Description Retrieves a list of published channels. Supports pagination. ### Method GET ### Endpoint /v2/channels ### Query Parameters - **page** (integer) - Optional - The page number for paginated results. - **per** (integer) - Optional - The number of items per page for paginated results. ### Request Example `GET http://api.are.na/v2/channels?page=2&per=15` ### Response #### Success Response (200) - **id** (integer) - The internal ID of the channel. - **title** (string) - The title of the channel. - **created_at** (timestamp) - Timestamp when the channel was created. - **updated_at** (timestamp) - Timestamp when the channel was last updated. - **published** (boolean) - If the channel is visible to all members of arena or not. - **open** (boolean) - If the channel is open to other members of arena for adding blocks. - **collaboration** (boolean) - If the channel has collaborators or not. - **slug** (string) - The slug of the channel used in the URL. - **length** (integer) - The number of items in a channel. - **kind** (string) - Can be either "default" or "profile". - **status** (string) - Can be "private", "closed", or "public". - **user_id** (integer) - Internal ID of the channel author. - **class** (string) - Will always be "Channel". - **base_class** (string) - Will always be "Channel". - **user** (hash) - More information on the channel author. - **follower_count** (integer) - Number of followers the channel has. #### Response Example { "channels": [ { "id": 123, "title": "Example Channel", "created_at": "2023-10-27T10:00:00Z", "updated_at": "2023-10-27T10:00:00Z", "published": true, "open": true, "collaboration": false, "slug": "example-channel", "length": 10, "kind": "default", "status": "public", "user_id": 456, "class": "Channel", "base_class": "Channel", "user": { "id": 456, "slug": "example-user", "first_name": "Example", "last_name": "User", "full_name": "Example User", "avatar": "...", "email": "example@example.com", "channel_count": 5, "following_count": 10, "follower_count": 20, "profile_id": 789 }, "follower_count": 5 } ], "total_pages": 1, "current_page": 1, "per": 15 } ``` -------------------------------- ### GET /v2/users/:id/following Source: https://dev.are.na/documentation/users Retrieves a list of all channels and users that the specified user is following. ```APIDOC ## GET /v2/users/:id/following ### Description Retrieves a list of all channels and users that the specified user is following. ### Method GET ### Endpoint /v2/users/:id/following ### Parameters #### Path Parameters - **id** (Integer) - Required - The internal ID of the user. ### Request Example ```http GET http://api.are.na/v2/users/17/following ``` ### Response #### Success Response (200) - Returns a list of channel and user objects that the specified user is following. ``` -------------------------------- ### GET /v2/search/channels?q=:q Source: https://dev.are.na/documentation/search Searches specifically for channels in the Are.na system whose titles or descriptions match the provided search query. Returns channel objects with pagination support. ```APIDOC ## GET /v2/search/channels?q=:q ### Description Performs a search query specifically for channels in the Are.na system. ### Method GET ### Endpoint http://api.are.na/v2/search/channels?q=:query ### Parameters #### Query Parameters - **q** (String) - Required - A string representation of your search query - **page** (Integer) - Optional - Page number for pagination - **per** (Integer) - Optional - Number of items per page ### Request Example GET http://api.are.na/v2/search/channels?q=arena ### Response #### Success Response (200) - **term** (String) - The search query term - **channels** (Array) - Array of channel objects matching the search query - **total_pages** (Integer) - Total number of pages available for this search - **current_page** (Integer) - Current page number in the paginated results - **per** (Integer) - Number of items per page ### Response Example { "term": "arena", "channels": [], "total_pages": 1, "current_page": 1, "per": 50 } ### Authentication Not required ### Pagination Supported ``` -------------------------------- ### GET /v2/search?q=:q Source: https://dev.are.na/documentation/search Performs a general search across all content types (blocks, users, and channels) in the Are.na system. Returns matching results for all resource types with pagination support. ```APIDOC ## GET /v2/search?q=:q ### Description Performs a general search query across the entire Are.na system, returning matching blocks, users, and channels. ### Method GET ### Endpoint http://api.are.na/v2/search?q=:query ### Parameters #### Query Parameters - **q** (String) - Required - A string representation of your search query - **page** (Integer) - Optional - Page number for pagination - **per** (Integer) - Optional - Number of items per page ### Request Example GET http://api.are.na/v2/search?q=art ### Response #### Success Response (200) - **term** (String) - The search query term - **users** (Array) - Array of user objects matching the search query - **channels** (Array) - Array of channel objects matching the search query - **blocks** (Array) - Array of block objects matching the search query - **total_pages** (Integer) - Total number of pages available for this search - **current_page** (Integer) - Current page number in the paginated results - **per** (Integer) - Number of items per page ### Response Example { "term": "art", "users": [], "channels": [], "blocks": [], "total_pages": 1, "current_page": 1, "per": 50 } ### Authentication Not required ### Pagination Supported ``` -------------------------------- ### GET /v2/channels/:slug Source: https://dev.are.na/documentation/channels Retrieves a complete representation of a channel. Channel contents can be paginated. ```APIDOC ## GET /v2/channels/:slug ### Description Retrieves a complete representation of a channel. Channel contents can be paginated. ### Method GET ### Endpoint /v2/channels/:slug ### Path Parameters - **slug** (string) - Required - The slug of the channel to retrieve. ### Query Parameters - **page** (integer) - Optional - The page number for paginated results. - **per** (integer) - Optional - The number of items per page for paginated results. ### Request Example `GET http://api.are.na/v2/channels/faq` ### Response #### Success Response (200) - **id** (integer) - The internal ID of the channel. - **title** (string) - The title of the channel. - **created_at** (timestamp) - Timestamp when the channel was created. - **updated_at** (timestamp) - Timestamp when the channel was last updated. - **published** (boolean) - If the channel is visible to all members of arena or not. - **open** (boolean) - If the channel is open to other members of arena for adding blocks. - **collaboration** (boolean) - If the channel has collaborators or not. - **slug** (string) - The slug of the channel used in the URL. - **length** (integer) - The number of items in a channel. - **kind** (string) - Can be either "default" or "profile". - **status** (string) - Can be "private", "closed", or "public". - **user_id** (integer) - Internal ID of the channel author. - **class** (string) - Will always be "Channel". - **base_class** (string) - Will always be "Channel". - **user** (hash) - More information on the channel author. - **follower_count** (integer) - Number of followers the channel has. - **contents** (array, can be null) - Array of blocks and other channels in the channel. - **collaborators** (array, can be null) - Collaborators on the channel. #### Response Example { "id": 789, "title": "FAQ", "created_at": "2023-10-27T10:00:00Z", "updated_at": "2023-10-27T10:00:00Z", "published": true, "open": false, "collaboration": false, "slug": "faq", "length": 5, "kind": "default", "status": "public", "user_id": 101, "class": "Channel", "base_class": "Channel", "user": { "id": 101, "slug": "arena-support", "first_name": "Arena", "last_name": "Support", "full_name": "Arena Support", "avatar": "...", "email": "support@are.na", "channel_count": 2, "following_count": 5, "follower_count": 50, "profile_id": 102 }, "follower_count": 10, "contents": [ { "id": 1001, "title": "What is Are.na?", "created_at": "2023-10-27T10:00:00Z", "updated_at": "2023-10-27T10:00:00Z", "user_id": 101, "class": "Block", "base_class": "Block", "content": "Are.na is a platform for...", "position": 1, "selected": false, "connected_at": "2023-10-27T10:00:00Z", "connected_by_user_id": 101 } ], "collaborators": [] } ``` -------------------------------- ### GET /v2/search/blocks?q=:q Source: https://dev.are.na/documentation/search Searches specifically for blocks in the Are.na system whose content matches the provided search query. Returns block objects with pagination support. ```APIDOC ## GET /v2/search/blocks?q=:q ### Description Performs a search query specifically for blocks in the Are.na system. ### Method GET ### Endpoint http://api.are.na/v2/search/blocks?q=:query ### Parameters #### Query Parameters - **q** (String) - Required - A string representation of your search query - **page** (Integer) - Optional - Page number for pagination - **per** (Integer) - Optional - Number of items per page ### Request Example GET http://api.are.na/v2/search/blocks?q=painting ### Response #### Success Response (200) - **term** (String) - The search query term - **blocks** (Array) - Array of block objects matching the search query - **total_pages** (Integer) - Total number of pages available for this search - **current_page** (Integer) - Current page number in the paginated results - **per** (Integer) - Number of items per page ### Response Example { "term": "painting", "blocks": [], "total_pages": 1, "current_page": 1, "per": 50 } ### Authentication Not required ### Pagination Supported ``` -------------------------------- ### Access Token Response (JSON) Source: https://dev.are.na/documentation/authentication This is an example of the JSON response received after successfully requesting an access token. It includes the access token itself, its type, and an expiration time (which is null in this case). ```json { "access_token": "ACCESS_TOKEN", "token_type": "bearer", "expires_in": null } ``` -------------------------------- ### GET /v2/users/:id/followers Source: https://dev.are.na/documentation/users Retrieves a list of users who are following the specified user. ```APIDOC ## GET /v2/users/:id/followers ### Description Retrieves a list of users who are following the specified user. ### Method GET ### Endpoint /v2/users/:id/followers ### Parameters #### Path Parameters - **id** (Integer) - Required - The internal ID of the user. ### Request Example ```http GET http://api.are.na/v2/users/17/followers ``` ### Response #### Success Response (200) - Returns a list of user objects who are following the specified user. ``` -------------------------------- ### GET /v2/search/users?q=:q Source: https://dev.are.na/documentation/search Searches specifically for users in the Are.na system whose profile information matches the provided search query. Returns user objects with pagination support. ```APIDOC ## GET /v2/search/users?q=:q ### Description Performs a search query specifically for users in the Are.na system. ### Method GET ### Endpoint http://api.are.na/v2/search/users?q=:query ### Parameters #### Query Parameters - **q** (String) - Required - A string representation of your search query - **page** (Integer) - Optional - Page number for pagination - **per** (Integer) - Optional - Number of items per page ### Request Example GET http://api.are.na/v2/search/users?q=dan ### Response #### Success Response (200) - **term** (String) - The search query term - **users** (Array) - Array of user objects matching the search query - **total_pages** (Integer) - Total number of pages available for this search - **current_page** (Integer) - Current page number in the paginated results - **per** (Integer) - Number of items per page ### Response Example { "term": "dan", "users": [], "total_pages": 1, "current_page": 1, "per": 50 } ### Authentication Not required ### Pagination Supported ``` -------------------------------- ### GET /v2/channels/:slug/thumb Source: https://dev.are.na/documentation/channels Retrieves basic information for constructing a small channel representation, including the first 9 blocks. This may change in future versions. ```APIDOC ## GET /v2/channels/:slug/thumb ### Description Retrieves basic information for constructing a small channel representation, including the first 9 blocks. This may change in future versions. ### Method GET ### Endpoint /v2/channels/:slug/thumb ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. ### Response #### Success Response (200) - **blocks** (array) - An array of block objects within the channel. #### Response Example { "blocks": [ { "id": "6513a1f81767b0001297803f", "title": "Block 1", "content": { "body": "This is the content of block 1." }, "created_at": "2023-09-25T10:00:00Z" } ] } ``` -------------------------------- ### GET Block Channels - Are.na API Source: https://dev.are.na/documentation/blocks Retrieves a paginated list of channels that a specific block exists in. This GET request does not require authentication. The response is a list of channels. ```http GET http://api.are.na/v2/blocks/8693/channels ``` -------------------------------- ### GET /v2/channels/:id/channels Source: https://dev.are.na/documentation/channels Returns all of the channels connected to blocks in the channel. Supports pagination. ```APIDOC ## GET /v2/channels/:id/channels ### Description Returns all of the channels connected to blocks in the channel. Supports pagination. ### Method GET ### Endpoint /v2/channels/:id/channels ### Parameters #### Path Parameters - **id** (string) - Required - The unique identifier for the channel. #### Query Parameters - **page** (integer) - Optional - The page number for pagination. - **per** (integer) - Optional - The number of results per page. ### Response #### Success Response (200) - **channels** (array) - An array of connected channel objects. #### Response Example { "channels": [ { "id": "6513a1f81767b00012978040", "title": "Connected Channel" } ] } ``` -------------------------------- ### GET /v2/users/:id/channels Source: https://dev.are.na/documentation/users Retrieves a list of all channels owned or collaborated on by the specified user. ```APIDOC ## GET /v2/users/:id/channels ### Description Retrieves a list of all channels owned or collaborated on by the specified user. ### Method GET ### Endpoint /v2/users/:id/channels ### Parameters #### Path Parameters - **id** (Integer) - Required - The internal ID of the user. ### Request Example ```http GET http://api.are.na/v2/users/17/channels ``` ### Response #### Success Response (200) - Returns a list of channel objects that the user is associated with. ``` -------------------------------- ### GET /v2/channels/:id/contents Source: https://dev.are.na/documentation/channels Returns all the contents of a channel. Does not include metadata like collaborators. Supports pagination. ```APIDOC ## GET /v2/channels/:id/contents ### Description Returns all the contents of a channel. Does not include metadata like collaborators. Supports pagination. ### Method GET ### Endpoint /v2/channels/:id/contents ### Parameters #### Path Parameters - **id** (string) - Required - The unique identifier for the channel. #### Query Parameters - **page** (integer) - Optional - The page number for pagination. - **per** (integer) - Optional - The number of results per page. ### Response #### Success Response (200) - **contents** (array) - An array of content objects within the channel. #### Response Example { "contents": [ { "id": "6513a1f81767b0001297803f", "title": "Content Title", "content": { "body": "Content body" } } ] } ``` -------------------------------- ### Get Block by ID (API V2) Source: https://dev.are.na/documentation/blocks Retrieves the full representation of a specific block using its unique ID. This is a GET request that does not require authentication and returns detailed information about the block. ```HTTP GET http://api.are.na/v2/blocks/:id ``` ```HTTP GET http://api.are.na/v2/blocks/8693 ``` -------------------------------- ### Get Channel Collaborators via API Source: https://dev.are.na/documentation/channels Retrieves a list of all members associated with a channel, excluding the channel owner. This GET request does not require authentication. It's useful for understanding who has access to a channel. ```HTTP GET http://api.are.na/v2/channels/arena-influences/collaborators ``` -------------------------------- ### GET /v2/channels/:id/connections Source: https://dev.are.na/documentation/channels Returns all the connections within a channel without fetching actual objects. Supports pagination. ```APIDOC ## GET /v2/channels/:id/connections ### Description Returns all the connections within a channel without fetching actual objects. Supports pagination. ### Method GET ### Endpoint /v2/channels/:id/connections ### Parameters #### Path Parameters - **id** (string) - Required - The unique identifier for the channel. #### Query Parameters - **page** (integer) - Optional - The page number for pagination. - **per** (integer) - Optional - The number of results per page. ### Response #### Success Response (200) - **connections** (array) - An array of connection objects. #### Response Example { "connections": [ { "id": "6513a1f81767b0001297803f", "connected_channel_id": "6513a1f81767b00012978040" } ] } ``` -------------------------------- ### List Users a User is Following (GET /v2/users/:id/following) Source: https://dev.are.na/documentation/users Retrieves a list of channels and users that a specific user is following. This endpoint does not require authentication and returns a list of followed entities. ```shell GET http://api.are.na/v2/users/17/following ``` -------------------------------- ### GET /v2/channels/:slug/collaborators Source: https://dev.are.na/documentation/channels Returns all members that are part of a channel. Does not return the channel owner. Requires authentication. ```APIDOC ## GET /v2/channels/:slug/collaborators ### Description Returns all members that are part of a channel. Does not return the channel owner. Requires authentication. ### Method GET ### Endpoint /v2/channels/:slug/collaborators ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. ### Response #### Success Response (200) - **collaborators** (array) - An array of collaborator objects. #### Response Example { "collaborators": [ { "id": "user_id_1", "username": "collaborator1" } ] } ``` -------------------------------- ### List a User's Channels (GET /v2/users/:id/channels) Source: https://dev.are.na/documentation/users Fetches a list of all channels owned or collaborated on by a specific user. This endpoint does not require authentication and returns a list of channel objects. ```shell GET http://api.are.na/v2/users/17/channels ``` -------------------------------- ### List Users Following a User (GET /v2/users/:id/followers) Source: https://dev.are.na/documentation/users Fetches a list of users who are following the specified user. This endpoint does not require authentication and returns a list of user objects representing followers. ```shell GET http://api.are.na/v2/users/17/followers ``` -------------------------------- ### Get Channel Thumbnails via API Source: https://dev.are.na/documentation/channels Retrieves basic information for a channel's representation, currently returning the first 9 blocks. This endpoint is public and does not require authentication. It is useful for generating small previews of channel content. ```HTTP GET http://api.are.na/v2/channels/arena-influences/thumb ``` -------------------------------- ### GET /v2/users/:id/channel Source: https://dev.are.na/documentation/users Redirects to the channel associated with the user. This is often the user's primary or profile channel. ```APIDOC ## GET /v2/users/:id/channel ### Description Redirects to the channel associated with the user. This is often the user's primary or profile channel. ### Method GET ### Endpoint /v2/users/:id/channel ### Parameters #### Path Parameters - **id** (Integer) - Required - The internal ID of the user. ### Request Example ```http GET http://api.are.na/v2/users/17/channel ``` ### Response #### Success Response (200) Redirects to `/v2/channels/:id` ``` -------------------------------- ### GET /v2/blocks/:id Source: https://dev.are.na/documentation/blocks Retrieves the full representation of a specific block using its unique ID. ```APIDOC ## GET /v2/blocks/:id ### Description Retrieves the full representation of a specific block using its unique ID. This endpoint provides detailed information about a block, including its attributes, content, and connection information. ### Method GET ### Endpoint /v2/blocks/:id ### Parameters #### Path Parameters - **id** (Integer) - Required - The unique identifier of the block to retrieve. ### Request Example ```bash GET http://api.are.na/v2/blocks/8693 ``` ### Response #### Success Response (200) - **id** (Integer) - The internal ID of the block. - **title** (String, can be null) - The title of the block. - **updated_at** (Timestamp) - Timestamp when the block was last updated. - **created_at** (Timestamp) - Timestamp when the block was created. - **state** (String) - Represents the state of the blocks processing lifecycle. - **comment_count** (Integer) - The number of comments on a block. - **generated_title** (String) - A generated title for the block. - **class** (String) - The type of block (e.g., "Image", "Text"). - **base_class** (String) - Always "Block". - **content** (String, can be null) - The text content of the block in markdown format (if applicable). - **content_html** (String, can be null) - The text content of the block in HTML format (if applicable). - **description** (String, can be null) - A description or caption for the block in markdown format. - **description_html** (String, can be null) - A description or caption for the block in HTML format. - **source** (Hash, can be null) - Information about the source if the block was saved from the web. - **image** (Hash, can be null) - Image-related information if the block is of type "Image" or "Link". - **user** (Hash) - Representation of the author of the block. - **connections** (Array) - An array of channel representations the block appears in. #### Response Example ```json { "id": 8693, "title": "Example Block Title", "updated_at": "2023-10-27T10:00:00Z", "created_at": "2023-10-26T09:00:00Z", "state": "Available", "comment_count": 5, "generated_title": "Example Block Title", "class": "Text", "base_class": "Block", "content": "# Hello, World!\n\nThis is an example text block.", "content_html": "
This is an example text block.
", "description": "A sample block for demonstration.", "description_html": "A sample block for demonstration.
", "source": null, "image": null, "user": { "id": 123, "username": "example_user" }, "connections": [ { "id": 456, "channel_id": 789, "created_at": "2023-10-26T09:05:00Z" } ] } ``` ``` -------------------------------- ### GET /oauth/authorize Source: https://dev.are.na/documentation/authentication Initiates the OAuth 2.0 authorization flow by redirecting users to the authorization endpoint. Users grant permission for your application to access their Arena account. Upon authorization, users are redirected back to your callback URL with an authorization code. ```APIDOC ## GET /oauth/authorize ### Description Redirects the user to Arena's authorization page where they can grant your application permission to access their account. ### Method GET ### Endpoint http://dev.are.na/oauth/authorize ### Query Parameters - **client_id** (string) - Required - Your application's unique client identifier - **redirect_uri** (string) - Required - The callback URL where users will be redirected after authorization - **response_type** (string) - Required - Must be set to "code" for authorization code flow ### Request Example http://dev.are.na/oauth/authorize?client_id=YOUR_CLIENT_ID&redirect_uri=YOUR_CALLBACK_URL&response_type=code ### Response #### Success Response (302 Redirect) User is redirected to YOUR_CALLBACK_URL with authorization code #### Response Example YOUR_CALLBACK_URL/?code=CODE ``` -------------------------------- ### GET /v2/blocks/:id/channels Source: https://dev.are.na/documentation/blocks Retrieves a paginated list of channels that a specific block exists in. This endpoint does not require authentication. ```APIDOC ## GET /v2/blocks/:id/channels ### Description Returns a paginated list of channels the block exists in. ### Method GET ### Endpoint /v2/blocks/:id/channels ### Parameters #### Path Parameters - **id** (integer) - Required - The ID of the block. #### Query Parameters - **page** (integer) - Optional - The page number for pagination. - **per** (integer) - Optional - The number of results per page. ### Request Example ``` GET http://api.are.na/v2/blocks/8693/channels ``` ### Response #### Success Response (200) - **channels** (array) - A list of channels the block belongs to. - **id** (integer) - The channel ID. - **title** (string) - The channel title. - **slug** (string) - The channel slug. #### Response Example ```json { "channels": [ { "id": 123, "title": "Example Channel", "slug": "example-channel" } ] } ``` ``` -------------------------------- ### Retrieve User's Channel Redirect (GET /v2/users/:id/channel) Source: https://dev.are.na/documentation/users Retrieves the primary channel associated with a user. This endpoint performs a redirect to the /v2/channels/:id endpoint and does not require authentication. ```shell GET http://api.are.na/v2/users/17/channel ``` -------------------------------- ### GET List of Published Channels - Arena API V2 Source: https://dev.are.na/documentation/channels Retrieves a paginated list of published channels from the Arena API. Supports pagination parameters (page and per) to control result set size and offset. Does not require authentication and returns only publicly visible channels. ```http GET http://api.are.na/v2/channels?page=2&per=15 ``` -------------------------------- ### Retrieve a User by ID (GET /v2/users/:id) Source: https://dev.are.na/documentation/users Fetches a specific user's object using their unique ID. This endpoint does not require authentication and returns a JSON object representing the user. ```shell GET http://api.are.na/v2/users/17 ``` -------------------------------- ### Get Channel Connections via API Source: https://dev.are.na/documentation/channels Fetches all connections within a specified channel without retrieving the actual block objects. This endpoint supports pagination and is publicly accessible. It's useful for understanding the network of connections within a channel. ```HTTP GET http://api.are.na/v2/channels/arena-influences/connections ``` -------------------------------- ### GET /v2/users/:id Source: https://dev.are.na/documentation/users Retrieves a specific user object by their unique ID. This endpoint provides detailed information about a user, including their attributes and counts. ```APIDOC ## GET /v2/users/:id ### Description Retrieves a specific user object by their unique ID. This endpoint provides detailed information about a user, including their attributes and counts. ### Method GET ### Endpoint /v2/users/:id ### Parameters #### Path Parameters - **id** (Integer) - Required - The internal ID of the user. ### Request Example ```http GET http://api.are.na/v2/users/17 ``` ### Response #### Success Response (200) - **id** (Integer) - The internal ID of the user. - **slug** (String) - The slug of the user. This is used for the user's default profile channel. - **username** (String) - Currently this will be equivalent to "full_name". - **first_name** (String) - The first name of the user. - **last_name** (String) - The last name of the user. - **avatar** (String) - The gravatar URL to the user's avatar. - **channel_count** (Integer) - The number of channels the user owns or is a collaborator on. - **following_count** (Integer) - The number of channels and users a user is following. - **profile_id** (Integer) - The internal ID of the user's profile channel. - **follower_count** (String) - The number of users following the user. - **class** (String) - Will always be "User". - **initials** (String) - The initials of a user. Derived from the user's first and last name. #### Response Example { "id": 17, "slug": "are-na", "username": "Are.na", "first_name": "Are.na", "last_name": "", "avatar": "https://d2ks0lst0c4q9p.cloudfront.net/images/6f1f3895155933a1646e19b2e119e36e.png", "channel_count": 18, "following_count": 19, "profile_id": 18, "follower_count": "14835", "class": "User", "initials": "A.a" } ``` -------------------------------- ### Get Channel Contents via API Source: https://dev.are.na/documentation/channels Returns all content items within a channel, excluding metadata like collaborators. This endpoint supports pagination and does not require authentication. It provides a direct way to access the primary content of a channel. ```HTTP GET http://api.are.na/v2/channels/arena-influences/contents ``` -------------------------------- ### GET Channel by Slug - Arena API V2 Source: https://dev.are.na/documentation/channels Retrieves a complete representation of a specific channel using its slug identifier. Returns full channel details including contents and metadata. Channel contents can be paginated separately. Does not require authentication to access public channels. ```http GET http://api.are.na/v2/channels/:slug ``` ```http GET http://api.are.na/v2/channels/faq ``` -------------------------------- ### Get Channels Connected to a Channel's Blocks via API Source: https://dev.are.na/documentation/channels Retrieves all channels that are connected to the blocks within a given channel. This endpoint supports pagination and is publicly accessible. It's valuable for exploring relationships and spidering connections between different channels. ```HTTP GET http://api.are.na/v2/channels/arena-influences/channels ``` -------------------------------- ### POST /v2/channels Source: https://dev.are.na/documentation/channels Creates a new channel. Requires authentication. ```APIDOC ## POST /v2/channels ### Description Creates a new channel. Requires authentication. ### Method POST ### Endpoint /v2/channels ### Parameters #### Request Body - **title** (string) - Required - Title of the channel. - **status** (string) - Optional - Sets the visibility of the channel. Can be: ["public", "closed", "private"]. Defaults to "public". ### Request Example { "title": "My New Channel", "status": "public" } ### Response #### Success Response (200) - **id** (string) - The ID of the newly created channel. - **title** (string) - The title of the channel. - **status** (string) - The visibility status of the channel. #### Response Example { "id": "6513a1f81767b00012978041", "title": "My New Channel", "status": "public" } ``` -------------------------------- ### Request Authorization for Access Token (HTTP) Source: https://dev.are.na/documentation/authentication This snippet shows how to redirect users to the authorize endpoint to begin the authentication process. It requires your application's client ID and a callback URL. ```http http://dev.are.na/oauth/authorize ?client_id=YOUR_CLIENT_ID &redirect_uri=YOUR_CALLBACK_URL &response_type=code ``` -------------------------------- ### Request Access Token using Code (HTTP) Source: https://dev.are.na/documentation/authentication This snippet demonstrates how to exchange an authorization code for an access token using a POST request to the token endpoint. It requires your client ID, client secret, the returned code, and your callback URL. ```http POST https://dev.are.na/oauth/token ?client_id=THE_ID &client_secret=THE_SECRET &code=RETURNED_CODE &grant_type=authorization_code &redirect_uri=YOUR_CALLBACK_URL ``` -------------------------------- ### POST /v2/channels/:slug/blocks Source: https://dev.are.na/documentation/channels Creates a new block and adds it to the specified channel. Requires authentication. Either 'source' or 'content' is required, but not both. ```APIDOC ## POST /v2/channels/:slug/blocks ### Description Creates a new block and adds it to the specified channel. Requires authentication. Either 'source' or 'content' is required, but not both. ### Method POST ### Endpoint /v2/channels/:slug/blocks ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. #### Request Body - **source** (string) - Required* - URL of content. Can be an Image, Embed, or Link. - **content** (string) - Required* - Textual content that's rendered with Github Flavored Markdown. ### Request Example { "source": "http://example.com/image.jpg" } ### Response #### Success Response (200) - **id** (string) - The ID of the newly created block. - **title** (string) - The title of the block. - **content** (object) - The content of the block. #### Response Example { "id": "6513a1f81767b00012978042", "title": "New Block", "content": { "body": "Content of the new block." } } ``` -------------------------------- ### POST Create Block - Are.na API Source: https://dev.are.na/documentation/blocks Creates a new block and adds it to a specified channel. This POST request requires authentication. Either a source URL or content is required. The content can be Markdown formatted text. ```http POST http://api.are.na/v2/channels/:slug/blocks Parameters: :source_ (required*): URL of content. Can be an Image, Embed, or Link. :content_ (required*): Textual content that's rendered with Github Flavored Markdown. _Either *:source_ or _:content_ is required. Not both. ``` -------------------------------- ### Create a New Channel via API Source: https://dev.are.na/documentation/channels Creates a new channel with a specified title and an optional status (public, closed, private). This is a POST request that requires authentication. The title parameter is mandatory. ```HTTP POST http://api.are.na/v2/channels Parameters: _:title_ (required) Title of the channel _:status_ (optional) Sets the visibility of the channel. Can be: ["public", "closed", "private"] Defaults to "public" ``` -------------------------------- ### POST /v2/channels/:slug/blocks Source: https://dev.are.na/documentation/blocks Creates a new block and adds it to the specified channel. Requires authentication. Either a source URL or content is required. ```APIDOC ## POST /v2/channels/:slug/blocks ### Description Creates a new block and adds it to the specified channel. ### Method POST ### Endpoint /v2/channels/:slug/blocks ### Parameters #### Path Parameters - **slug** (string) - Required - The slug of the channel to add the block to. #### Request Body - **source** (string) - Optional - URL of content (Image, Embed, or Link). - **content** (string) - Optional - Textual content rendered with Github Flavored Markdown. *Note: Either `source` or `content` is required. Not both.* ### Request Example ```json { "source": "http://example.com/image.jpg" } ``` ### Response #### Success Response (201) - **id** (integer) - The ID of the newly created block. - **title** (string) - The title of the block. - **content** (string) - The content of the block. #### Response Example ```json { "id": 456, "title": "New Block", "content": "This is the content of the new block." } ``` ``` -------------------------------- ### POST /v2/channels/:slug/collaborators Source: https://dev.are.na/documentation/channels Adds collaborators to a channel. Accepts a serialized list of user IDs. Requires authentication. ```APIDOC ## POST /v2/channels/:slug/collaborators ### Description Adds collaborators to a channel. Accepts a serialized list of user IDs. Requires authentication. ### Method POST ### Endpoint /v2/channels/:slug/collaborators ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. #### Request Body - **ids** (array of strings) - Required - A serialized list of user IDs to add as collaborators. ### Request Example { "ids": ["user_id_1", "user_id_2"] } ### Response #### Success Response (200) - **collaborators** (array) - The current list of collaborators in the channel. #### Response Example { "collaborators": [ { "id": "user_id_1", "username": "collaborator1" }, { "id": "user_id_2", "username": "collaborator2" } ] } ``` -------------------------------- ### Add a Block to a Channel via API Source: https://dev.are.na/documentation/channels Creates a new block within a specified channel. The block can be created from a source URL or textual content, but not both. This POST request requires authentication and either the 'source' or 'content' parameter. ```HTTP POST /v2/channels/:slug/blocks Parameters: _:source_ (required*) URL of content. Can be an Image, Embed, or Link. _:content_ (required*) Textual content that's rendered with Github Flavored Markdown. Either *:source_ or _:content_ is required. Not both. ``` -------------------------------- ### Add Collaborators to a Channel via API Source: https://dev.are.na/documentation/channels Adds collaborators to a channel by accepting a serialized list of user IDs. This POST request requires authentication and returns the updated list of collaborators. Use this to grant access to specific users. ```HTTP POST http://api.are.na/v2/channels/:slug/collaborators Example Request: POST http://api.are.na/v2/channels/arena-influences/collaborators Accepts a serialized list of ids. Returns the current list of collaborators ``` -------------------------------- ### PUT /v2/channels/:slug Source: https://dev.are.na/documentation/channels Updates the attributes of an existing channel. Requires authentication. ```APIDOC ## PUT /v2/channels/:slug ### Description Updates the attributes of an existing channel. Requires authentication. ### Method PUT ### Endpoint /v2/channels/:slug ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. #### Request Body - **title** (string) - Optional - Title of the channel. - **status** (string) - Optional - Sets the visibility of the channel. Can be: ["public", "closed", "private"]. Defaults to "public". ### Request Example { "title": "Updated Channel Title" } ### Response #### Success Response (200) - **id** (string) - The ID of the updated channel. - **title** (string) - The updated title of the channel. - **status** (string) - The updated visibility status of the channel. #### Response Example { "id": "6513a1f81767b0001297803f", "title": "Updated Channel Title", "status": "public" } ``` -------------------------------- ### PUT /v2/channels/:slug/sort Source: https://dev.are.na/documentation/channels Updates the order of blocks within a channel by providing a serialized array of block IDs. Requires authentication. ```APIDOC ## PUT /v2/channels/:slug/sort ### Description Updates the order of blocks within a channel by providing a serialized array of block IDs. Requires authentication. ### Method PUT ### Endpoint /v2/channels/:slug/sort ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. #### Request Body - **ids** (array of strings) - Required - Serialized array of block IDs in the desired order. ### Request Example { "ids": ["block_id_1", "block_id_2", "block_id_3"] } ### Response #### Success Response (200) - **message** (string) - Confirmation message indicating the order was updated. #### Response Example { "message": "Channel order updated successfully." } ``` -------------------------------- ### Reorder Channel Blocks via API Source: https://dev.are.na/documentation/channels Updates the order of blocks within a channel by accepting a serialized array of block IDs. This PUT request requires authentication and the 'ids' parameter, which is a required serialized array. ```HTTP PUT http://api.are.na/v2/channels/:slug/sort Parameters: _:ids_ (required) Serialized array of IDs ``` -------------------------------- ### Update Channel Attributes via API Source: https://dev.are.na/documentation/channels Updates the attributes of an existing channel, such as its title or status. This PUT request requires authentication. Both title and status are optional parameters. ```HTTP PUT http://api.are.na/v2/channels/:slug Parameters: _:title_ (optional) Title of the channel _:status_ (optional) Sets the visibility of the channel. Can be: ["public", "closed", "private"] Defaults to "public" ``` -------------------------------- ### PUT Update Block - Are.na API Source: https://dev.are.na/documentation/blocks Updates a block's attributes such as title, description, or content. This PUT request does not require authentication. The description and content parameters accept Markdown formatted text. ```http PUT http://api.are.na/v2/blocks/:id Parameters: :title_ (optional) :description_ (optional) - Markdown formatted text. :content_ (optional) - Markdown formatted text. For text block type only. ``` -------------------------------- ### DELETE /v2/channels/:slug Source: https://dev.are.na/documentation/channels Destroys the specified channel and its connections to content. The content itself is not destroyed. Requires authentication. ```APIDOC ## DELETE /v2/channels/:slug ### Description Destroys the specified channel and its connections to content. The content itself is not destroyed. Requires authentication. ### Method DELETE ### Endpoint /v2/channels/:slug ### Parameters #### Path Parameters - **slug** (string) - Required - The unique identifier for the channel. ### Response #### Success Response (200) - **message** (string) - Confirmation message indicating the channel was deleted. #### Response Example { "message": "Channel deleted successfully." } ```