Getting started overview

Getting started with IPS Online involves a sequence of steps designed to enable rapid integration of its computer vision capabilities into applications. The process begins with account creation, which grants access to the IPS Online developer portal and API keys. These keys are essential for authenticating requests to the Image Tagging, Object Detection, Facial Recognition, and Content Moderation APIs. Following authentication, developers can make their first API call, often using one of the provided SDKs, such as Python or Node.js, to process an image and receive structured data in response. IPS Online offers a free tier of 5,000 API calls per month for initial development and testing.

The following table outlines the key steps to begin using IPS Online:

Step What to Do Where
1. Create Account Register for a new IPS Online developer account. IPS Online homepage
2. Obtain API Keys Locate your unique API key and secret in the developer dashboard. IPS Online dashboard (after login)
3. Install SDK (Optional) Install the appropriate SDK for your programming language (e.g., Python, Node.js). IPS Online documentation on SDKs
4. Make First Request Write and execute code to send an image to an IPS Online API endpoint. IPS Online API Reference
5. Process Response Parse the JSON response from the API to extract relevant information. IPS Online documentation on responses

Create an account and get keys

To access IPS Online's APIs, developers must first create an account. This process typically involves providing an email address and setting a password on the IPS Online website. Once registered and logged in, users are directed to a developer dashboard or console. Within this dashboard, unique API keys are generated and displayed. These keys consist of a public API key and often a secret key, which are critical for authenticating API requests.

The API keys serve as credentials to identify your application and authorize its access to IPS Online's services. It is a common practice in API development to treat secret keys as sensitive information, similar to passwords. They should be stored securely and not hardcoded directly into client-side applications or publicly accessible repositories. For server-side applications, environment variables or secure configuration management systems are recommended for storing API keys, a practice also advised by general security guidelines for API keys from sources like Google Cloud's API key security best practices.

To retrieve your IPS Online API keys:

  1. Navigate to the IPS Online homepage and click on 'Sign Up' or 'Get Started'.
  2. Complete the registration form with your details.
  3. Verify your email address if prompted.
  4. Log in to your newly created account.
  5. Access the 'API Keys' or 'Credentials' section within your developer dashboard.
  6. Copy your API Key and API Secret. Keep these secure.

Your first request

Making your first API request with IPS Online typically involves choosing an API (e.g., Image Tagging API), selecting an SDK, and then writing a small code snippet. IPS Online provides SDKs for several languages, including Python and Node.js, which simplify interaction with the API by handling authentication and request formatting.

The IPS Online API Reference provides detailed endpoints and parameters for each service. For this example, we will focus on the Image Tagging API, which is one of the core products.

Python Example (Image Tagging)

First, install the Python SDK:

pip install ipsonline-sdk

Then, make an image tagging request:

import os
from ipsonline_sdk import IPSOnlineClient

# Replace with your actual API Key and Secret
API_KEY = os.environ.get("IPS_ONLINE_API_KEY")
API_SECRET = os.environ.get("IPS_ONLINE_API_SECRET")

if not API_KEY or not API_SECRET:
    print("Please set IPS_ONLINE_API_KEY and IPS_ONLINE_API_SECRET environment variables.")
    exit()

client = IPSOnlineClient(api_key=API_KEY, api_secret=API_SECRET)

image_url = "https://example.com/path/to/your/image.jpg" # Replace with a valid image URL

try:
    response = client.image_tagging.analyze_image_url(url=image_url)
    print("Image Tagging Results:")
    for tag in response.get("tags", []):
        print(f"  Tag: {tag['name']}, Confidence: {tag['confidence']:.2f}")
except Exception as e:
    print(f"An error occurred: {e}")

Node.js Example (Image Tagging)

First, install the Node.js SDK:

npm install @ipsonline/sdk

Then, make an image tagging request:

require('dotenv').config(); // For loading .env file
const { IPSOnlineClient } = require('@ipsonline/sdk');

// Replace with your actual API Key and Secret or use environment variables
const API_KEY = process.env.IPS_ONLINE_API_KEY;
const API_SECRET = process.env.IPS_ONLINE_API_SECRET;

if (!API_KEY || !API_SECRET) {
  console.error('Please set IPS_ONLINE_API_KEY and IPS_ONLINE_API_SECRET environment variables.');
  process.exit(1);
}

const client = new IPSOnlineClient({ apiKey: API_KEY, apiSecret: API_SECRET });

const imageUrl = 'https://example.com/path/to/your/image.jpg'; // Replace with a valid image URL

(async () => {
  try {
    const response = await client.imageTagging.analyzeImageUrl({ url: imageUrl });
    console.log('Image Tagging Results:');
    response.tags.forEach(tag => {
      console.log(`  Tag: ${tag.name}, Confidence: ${tag.confidence.toFixed(2)}`);
    });
  } catch (error) {
    console.error(`An error occurred: ${error.message}`);
  }
})();

These examples demonstrate how to initialize the client with your credentials and call a specific API method, passing an image URL. The response is typically a JSON object containing the results of the image analysis, such as detected tags and their confidence scores.

Common next steps

After successfully making your first request, several common next steps can enhance your use of IPS Online's APIs:

  • Explore other APIs: IPS Online offers various computer vision APIs, including Object Detection, Facial Recognition, and Content Moderation. Review the API Reference to understand their capabilities and integrate them as needed.
  • Implement error handling: Production applications require robust error handling. Implement try-catch blocks or similar mechanisms to gracefully manage API errors, network issues, or invalid inputs. The IPS Online SDKs typically provide structured error responses that can be parsed for specific error codes and messages.
  • Monitor API usage: Keep track of your API call volume to stay within your free tier limits or monitor usage against your paid plan. The IPS Online dashboard usually provides usage analytics.
  • Optimize image input: For optimal performance and cost efficiency, consider optimizing images before sending them to IPS Online. This might involve resizing, compressing, or converting image formats to meet API specifications and reduce bandwidth.
  • Secure API keys: Reinforce the security of your API keys by implementing best practices such as storing them in environment variables, using a secrets management service, and rotating them regularly. Avoid embedding keys directly in code or public repositories.
  • Explore advanced features: Depending on your application's needs, investigate advanced features like batch processing, custom model training (if available), or webhook notifications for asynchronous results.
  • Review documentation and community resources: Regularly consult the official IPS Online documentation for updates, new features, and best practices. Participate in developer forums or communities if available, to share knowledge and seek assistance.

Troubleshooting the first call

When making your first API call to IPS Online, various issues can arise. Here are common problems and their potential solutions:

  • Invalid API Key or Secret:
    • Symptom: Authentication errors, 'Unauthorized' or 'Invalid Credentials' messages.
    • Solution: Double-check that your API Key and API Secret are copied correctly from your IPS Online dashboard. Ensure no extra spaces or characters are included. Verify that you are passing them correctly to the SDK client initialization.
  • Incorrect Endpoint or API Method:
    • Symptom: '404 Not Found' or 'Method Not Allowed' errors.
    • Solution: Consult the IPS Online API Reference to confirm you are using the correct endpoint URL and HTTP method (GET, POST) for the specific API you are calling (e.g., Image Tagging, Object Detection).
  • Missing or Invalid Parameters:
    • Symptom: 'Bad Request' (400) errors, or responses indicating missing required fields.
    • Solution: Review the API documentation for the specific method to ensure all required parameters (e.g., url for image analysis) are present and correctly formatted. Check for proper data types (string, integer, boolean) and value constraints.
  • Network or Connectivity Issues:
    • Symptom: Connection timeouts, 'Host Unreachable' errors.
    • Solution: Verify your internet connection. If running locally, check firewall settings. Ensure the target image URL (if providing one) is publicly accessible and correct.
  • Exceeded Free Tier Limits:
    • Symptom: Errors indicating 'Rate Limit Exceeded' or 'Quota Exhausted'.
    • Solution: Check your usage statistics in the IPS Online dashboard. If you've exhausted your free tier, you may need to wait for the next billing cycle or upgrade to a paid plan.
  • SDK Installation Problems:
    • Symptom: 'Module not found' or similar import errors.
    • Solution: Ensure the IPS Online SDK for your chosen language is correctly installed. For Python, use pip install ipsonline-sdk. For Node.js, use npm install @ipsonline/sdk. Verify your development environment's package paths.
  • Environment Variable Issues:
    • Symptom: API keys appear undefined or empty in code, leading to authentication errors.
    • Solution: Confirm that environment variables (e.g., IPS_ONLINE_API_KEY) are correctly set in your operating system or .env file and that your code is correctly reading them (e.g., using os.environ.get() in Python or process.env in Node.js).