1.2.7 • Published 5 months ago

awafim-sdk v1.2.7

Weekly downloads
-
License
MIT
Repository
-
Last release
5 months ago

Awafim.tv SDK 🎖️

Powers the 9ja movies / series on Clipsave. https://movies.clipsave.ng . https://series.clipsave.ng Might scrape for African movies / series soon.

Installation 📦

To install the package, depending on the package manager you're using. Run the following command:

npm install awafim-sdk

bun

bun install awafim-sdk

yarn

yarn add awafim-sdk

pnpm

pnpm add awafim-sdk

How To Use 🛠️

Before you can use any of the methods below, you need to import the SDK and initialize it.

import { AwaFimMovies } from "awafim-sdk";

const awaFimMovies = new AwaFimMovies();
  1. SearchMovie(name: string): Promise<Movie[]>

Description

Searches for movies on the AwaFim platform based on the provided name.

Parameters:

  • name (string): The name of the movie you want to search for.

  • Returns: A promise that resolves to an array of Movie objects containing basic details about the found movies.

Example:

const movies = await awaFimMovies.SearchMovie("Inception");
  1. getDownloadLink(movieUrl: string): Promise<{ downloadUrl: string }>

Description

Retrieves the download link for a movie from its URL.

Parameters:

  • movieUrl (string): The URL of the movie you want to download.

  • Returns: A promise that resolves to an object containing the downloadUrl.

Example:

const { downloadUrl } = await awaFimMovies.getDownloadLink(
  "https://www.awafim.tv/movie/123"
);
  1. getNollywoodMovies(pageNumber: number = 1): Promise<Movie[]>

Description

Fetches Nollywood movies from the AwaFim platform. You can specify the page number for pagination.

Parameters:

  • pageNumber (number): The page number to fetch (default is 1). It must be between 1 and MAX_NOLLYWOOD_MOVIE_PAGE.

  • Returns: A promise that resolves to an array of Movie objects containing basic details about the series.

Example:

const nollywoodMovies = await awaFimMovies.getNollywoodMovies(1);
  1. getNollywoodSeries(pageNumber: number = 1): Promise<Movie[]>

Description

Fetches Nollywood series from the AwaFim platform. You can specify the page number for pagination.

Parameters:

  • pageNumber (number): The page number to fetch (default is 1). It must be between 1 and MAX_NOLLYWOOD_SERIES_PAGE.

  • Returns: A promise that resolves to an array of Movie objects containing basic details about the series.

Example:

const nollywoodSeries = await awaFimMovies.getNollywoodSeries(1);
  1. getAllNollywoodShows(pageNumber: number = 1): Promise<Movie[]>

Description

Fetches all Nollywood shows (both movies and series) from the AwaFim platform. You can specify the page number for pagination.

Parameters:

  • pageNumber (number): The page number to fetch (default is 1). It must be between 1 and MAX_NOLLYWOOD_SHOW_PAGE.

  • Returns: A promise that resolves to an array of Movie objects containing basic details about the series.

Example:

const nollywoodShows = await awaFimMovies.getAllNollywoodShows(1);
1.2.7

5 months ago

1.2.6

5 months ago

1.2.5

9 months ago

1.2.4

10 months ago

1.2.3

10 months ago

1.2.2

10 months ago

1.2.1

11 months ago