API Base URL: https://do.schogini.com:8084/api/
This API provides endpoints for extracting entities, generating YouTube metadata, extracting contact details, language translation, language detection, and spam/phishing detection.
Method: Bearer Token
Header: Authorization: Bearer YOUR_API_KEY_HERE
Endpoint: /extract_entities
Method: POST
Description: Extracts specified entities from the provided text using OpenAI's language model.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here",
"entities": "comma-separated entities (e.g., 'persons, emails, phone_numbers')"
}
200 OK:
{
"extracted_entities": {
"persons": ["John Doe"],
"emails": ["john.doe@example.com"],
"phone_numbers": ["+11234567890"]
}
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /generate_youtube_metadata
Method: POST
Description: Generates YouTube metadata for SEO purposes based on the input text and target keywords.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here",
"target_keywords": "comma-separated keywords (e.g., 'SEO, video, YouTube')"
}
200 OK:
{
"youtube_metadata": {
"youtube_title": "Generated Title",
"youtube_description": "Generated description with SEO optimization.",
"hashtags": "#SEO #YouTube",
"keywords": "SEO, video, YouTube",
"meta_title": "Generated Meta Title",
"meta_description": "Generated meta description with SEO."
}
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /extract_contact_details
Method: POST
Description: Extracts contact details from the provided text, including name, email, phone, address, country, zip code, website, and business type.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here"
}
200 OK:
{
"contact_details": {
"name": "John Doe",
"email": "john.doe@example.com",
"phone": "+1 (555) 123-4567",
"address": "1234 Elm Street, Springfield, IL, 62704",
"country": "USA",
"zip_code": "62704",
"website": "www.techinnovations.com",
"type_of_business": "Tech Innovations Inc."
}
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /language_translation
Method: POST
Description: Translates the input text into the specified target language using OpenAI's language model.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here",
"target_language": "language to translate to (e.g., 'Spanish', 'French')"
}
200 OK:
{
"translated_text": "The translated text here"
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /language_detection
Method: POST
Description: Detects the language of the input text using OpenAI's language model.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here"
}
200 OK:
{
"language": "Detected language here"
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /spam_phishing_detection
Method: POST
Description: Detects whether a message or email contains spam, phishing content, or is legitimate.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here"
}
200 OK:
{
"classification": "Spam" | "Phishing" | "Legitimate"
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /content_moderation
Method: POST
Description: Analyzes the provided text for inappropriate or harmful content and categorizes it using OpenAI's Moderation API.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here"
}
200 OK:
{
"flagged": false,
"categories": {
"harassment": false,
"self-harm": false,
"sexual": false,
"violence": false
},
"category_scores": {
"harassment": 0.0002,
"self-harm": 0.0001,
"sexual": 0.0015,
"violence": 0.0189
}
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
Endpoint: /sentiment_analysis
Method: POST
Description: Analyzes the sentiment of the provided text and returns the sentiment as Positive, Negative, or Neutral using OpenAI's model.
Authorization: Bearer YOUR_API_KEY_HERE
Content-Type: application/json
{
"text": "Your input text here"
}
200 OK:
{
"sentiment": "positive" | "negative" | "neutral"
}
401 Unauthorized:
{
"error": "Unauthorized"
}
422 Unprocessable Entity:
{
"error": "Invalid input data"
}
curl -X POST "https://do.schogini.com:8084/api/extract_entities" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "John Doe from Acme Corp. will visit New York on October 5th. Contact him at john.doe@example.com or call +11234567890.",
"entities": "persons, emails, phone_numbers"
}'
curl -X POST "https://do.schogini.com:8084/api/generate_youtube_metadata" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "This is a video about improving SEO techniques for YouTube videos.",
"target_keywords": "SEO, YouTube, video marketing"
}'
curl -X POST "https://do.schogini.com:8084/api/extract_contact_details" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "John Doe, CEO of Tech Innovations Inc., can be reached at john.doe@example.com or +1 (555) 123-4567. The office is located at 1234 Elm Street, Springfield, IL, 62704, USA. Visit our website at www.techinnovations.com."
}'
curl -X POST "https://do.schogini.com:8084/api/language_translation" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "Hello, how are you?",
"target_language": "Spanish"
}'
curl -X POST "https://do.schogini.com:8084/api/language_detection" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "Bonjour, comment ça va?"
}'
curl -X POST "https://do.schogini.com:8084/api/spam_phishing_detection" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "You have won $1,000! Click this link to claim your prize."
}'
curl -X POST "https://do.schogini.com:8084/api/content_moderation" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "The text you want to analyze for moderation."
}'
curl -X POST "https://do.schogini.com:8084/api/sentiment_analysis" \
-H "Authorization: Bearer YOUR_API_KEY_HERE" \
-H "Content-Type: application/json" \
-d '{
"text": "This product is great! I love it."
}'