Skip to content

Instantly share code, notes, and snippets.

View PawanOsman's full-sized avatar

Pawan Osman PawanOsman

View GitHub Profile
@PawanOsman
PawanOsman / ip_routing_and_application_setup.md
Created August 3, 2023 07:16
This Gist contains instructions for configuring specific IP addresses and routing rules for network interfaces. It covers steps to validate IP connectivity, set up outgoing IP addresses, and update application code to manage source IPs for requests.

Step 1: Validate Routing to the Desired IP Address:

To ensure connectivity to your intended IP address, execute the following command to display network interface IP addresses:

ip addr show

In case the IP address is not visible under the relevant network interface, utilize the following command to add it:

@PawanOsman
PawanOsman / index.js
Last active December 13, 2023 19:45
This Node.js file is designed to revoke multiple OpenAI API keys. It allows users to input a list of API keys and automatically revokes them using OpenAI's API. The file utilizes the Axios library to send HTTP requests to the OpenAI API and parses the response to determine if the revocation was successful.
import axios from 'axios';
let keys = [ // Example, replace it with your own keys
"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",
"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",
"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",
"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",
"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",
"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",
"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",
@PawanOsman
PawanOsman / OAI-ReverseProxy-FREE.md
Created March 7, 2023 22:57
OAI Reverse Proxy - FREE

Introduction:

Reverse proxy to use OpenAI API Join Our Discord Server 😁

Features

  1. Works same as OpenAI API
  2. Supports Streaming!
  3. It's FREE!

Elevenlabs.io API Documentation

Endpoint

The Text-to-Speech API is available at the following endpoint: https://api.pawan.krd/tts

Methods

The API supports the following methods:

I created a dedicated HTTP API for official ChatGPT API, its using POST so it can handle long prompts and it supports setting all OpenAI properties

Example in NodeJS: (Its same for other languages you need to create a post request like below)

Ask ChatGPT a question

axios({
    method: 'post',
    url: 'https://chatgpt.pawan.krd/ask',
    headers: {
@PawanOsman
PawanOsman / LoadingPageBar.html
Last active January 7, 2020 07:19
Loading overlay - Demo by Roko C.B// source https://jsbin.com/hagehiyimu
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Loading overlay - Demo by Roko C.B</title>
<style id="jsbin-css">
*{margin:0;}
body{
font: 200 16px/1 Helvetica, Arial, sans-serif;