Build with MYETV

Leverage the power of our OAuth 2.0 based RESTful APIs to integrate Single Sign-On and content publishing directly into your applications.

API Documentation (v1)

Welcome to the official MYETV API documentation. All requests must be made over HTTPS to the https://developers.myetv.tv domain.

1. Application Types

When creating an App in the Developer Dashboard, you must define its core purpose. MYETV supports two distinct application architectures to maximize security:

🔐 Single Sign-On Only (SSO Login)

Designed purely for "Login with MYETV" integrations. These apps can only request basic profile information and email addresses. They cannot publish content, and users authorize them exclusively using their Personal Account.

⚙️ Full API Access

Designed for heavy integrations. These apps can read data and publish content. During authorization, users can choose whether to grant access to their Personal Account or on behalf of one of their specific Networks.

2. Authentication (OAuth 2.0)

MYETV uses standard OAuth 2.0 flows to allow apps to securely access accounts. We support two primary methods depending on your application execution environment.

Security Notice: API endpoints are protected by application-level firewalls and rate limiters to ensure platform stability. Repeated failed authentication attempts will result in a temporary IP ban.

Method A: Authorization Code Flow (For Third-Party Apps / Web Apps)

Use this flow when your app needs to act on behalf of a normal user, or if you want to implement a "Login with MYETV" button.

Scopes (Permissions): You must request specific permissions using the scope parameter. Separate multiple scopes with a space (URL encoded as %20 or +).

Step 1: Request Authorization - Redirect the user to request their consent:

GET /api/oauth/authorize.php?client_id=YOUR_CLIENT_ID&redirect_uri=YOUR_REDIRECT_URI&response_type=code&scope=profile email

Step 2: Exchange Code for Token - Your server exchanges the received code for an Access Token by making a POST request:

POST /api/oauth/token.php
Content-Type: application/x-www-form-urlencoded

grant_type=authorization_code
&client_id=YOUR_CLIENT_ID
&client_secret=YOUR_CLIENT_SECRET
&redirect_uri=YOUR_REDIRECT_URI
&code=RECEIVED_CODE

Method B: Client Credentials Flow (For Developers & M2M Scripts) ADVANCED

If you are building a server-to-server script or testing via cURL on your own account, you can bypass the browser authorization and generate a token directly using your App credentials.

Important: Before using this method, you must associate a Default M2M Execution Account (Personal Account or Network) to your Application via the App Dashboard.
POST /api/oauth/token.php
Content-Type: application/x-www-form-urlencoded

grant_type=client_credentials
&client_id=YOUR_CLIENT_ID
&client_secret=YOUR_CLIENT_SECRET

Success Response (Both Methods):

{
  "access_token": "f8a9b2c3d4e5f6g7h8i9...",
  "token_type": "Bearer",
  "expires_in": 5184000,
  "user_id": "a1b2c3d4"
}

3. Get Profile Information (User Info)

Once you have an Access Token, you can retrieve the details of the connected entity (Account or Network). This endpoint is heavily used to authenticate users into your system (Single Sign-On).

Endpoint
GET /api/v1/profile.php
Required Headers

Success Response (JSON):

{
  "id": "a1b2c3d4",
  "type": "account", // Can be 'account' or 'network'
  "name": "John Doe",
  "username": "johndoe89",
  "email": "johndoe@example.com", // Returned ONLY if 'email' scope was requested and granted
  "avatar": "https://www.myetv.tv/.../avatar.jpg",
  "profile_url": "https://www.myetv.tv/account/..."
}

4. Publish Content (POST Endpoint)

Use the Access Token to publish text, links, or images. Note: You do not need to specify who is publishing in the JSON payload. The API natively routes the post to the User's Board or the Network's Wall depending on the identity bound to the token.

RESTRICTION Tokens generated by apps categorized as SSO Login Only will receive a 403 Forbidden error if they attempt to hit this endpoint.

Endpoint
POST /api/v1/publishcontents.php
Required Headers
JSON Payload (Examples)

Example A: Plain Text Post

{
  "type": "text",
  "text": "This is a post sent via API! XD",
  "privacy": "public"
}

Example B: Link Sharing with Title & Preview Image

{
  "type": "link",
  "title": "Check out this awesome website!",
  "text": "Here are my thoughts on this...",
  "link_url": "https://www.example.com",
  "image_url": "https://www.example.com/preview.jpg",
  "privacy": "onlyfriends"
}

Example C: Image Publishing (Direct Upload)

{
  "type": "image",
  "text": "My new photo via API",
  "image_base64": "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQE...",
  "privacy": "public"
}
Payload Parameters
Field Type Description
type String Required. Allowed values: text, link, image.
title String Optional. The title of the content or the link being shared.
text String The text content or caption of the post.
link_url String (URL) Required if type is link. The API automatically detects authorized platforms.
image_url String (URL) Optional. Direct URL to an external image, ideal for link previews.
image_base64 String (Base64) Required if type is image and no image_url is provided. Max payload size is 10MB.
eflash String Optional. A comment or brief caption associated with the content or link.
scheduled_time String (Datetime) Optional. Desired future publication date and time (e.g., 2026-11-27 13:30:00).
timezone String (TZ) Optional. Default: UTC. The Timezone identifier (e.g., Europe/Rome).
privacy String Optional. Default: public. Allowed values: public, onlylogged, onlyfriends, private.
category_id Integer Optional. Default: 1. The numeric ID representing the content category.
language String (ISO3) Optional. Default: nts. The ISO3 code of the content language.
country String (ISO3) Optional. Default: INT. The ISO3 code of the content origin country.
Response (201 Created)
{
  "status": "success",
  "message": "Content published successfully.",
  "content_id": "4b2a8d1e",
  "url": "https://www.myetv.tv/play/4b2a8d1e"
}

5. Retrieve Content Details (GET Endpoint)

Retrieve detailed information about a specific content item using its unique ID. The API strictly enforces content privacy, geolanguage rules, and geo-blocking restrictions.

Endpoint
GET /api/v1/getcontent.php?id=CONTENT_ID&language=ISO3_CODE
Required Headers
Query Parameters
Field Type Description
id String Required. The unique ID of the content.
language String (ISO3) Optional. The ISO3 language code of the requesting user. Used to evaluate custom Geolanguage restrictions.
Success Response (200 OK)
{
  "status": "success",
  "data": {
    "id": "275103dd",
    "owner": "44",
    "title": "The Next Chapter of MyETV",
    "text": "Welcome to a brand new era of content creation...",
    "link": "https://blog.myetv.tv/...",
    "url": "https://www.myetv.tv/play/275103dd",
    "image": "https://blog.myetv.tv/wp-content/uploads/...",
    "duration": null,
    "type": "myeTV",
    "privacy": "public",
    "category_id": 1,
    "language": "nts",
    "country": "INT",
    "quality": "EURL",
    "eflash": "",
    "scheduled_at": "2026-05-08 18:01:18"
  }
}

6. Appendix: Category IDs

When publishing content, use the following numeric IDs for the category_id parameter:

ID Category Name
1Generic Content (general)
2Animals
3Autos and Vehicles (motors)
4How to...
5Film
6Games
7Education
8Music
9News
10NoProfit
11Blogs
12Science
13Shows
14Sport
15Events
16Funny Contents
17Pictures and Animated Images
18Advertisement
19Live Streaming
20Nature
21Style
22People
23Politic
24Travels
25Animation
26Activism
27Technology
28Television
29Series
30Entertainment
31Television Show
32History
33From the Web (online)
34Away From Keyboard (afk)
35Exploration
36Justice
37Legality
38Documentary
39Geography
40Mythology
41Geopolitics

7. Common Error Codes