RapidAPI logo

Sign Up

Log In

packit4me

FREE
By packit4me
Updated 3 months ago
Tools
5.1/10
Popularity Score
580ms
Latency
23%
Success Rate

packit4me API Documentation

A super simple, super awesome service. It provides an API for 2D/3D bin packing. Bin packing can be used for packing boxes for shipping departments, or it can be used as a form of conceptually allocating space. This can be for print layouts, or other types of material allocation.

View API Details
POSTraw
POSTraw

Raw JSON

Header Parameters
X-RapidAPI-HostSTRING
REQUIRED
X-RapidAPI-KeySTRING
REQUIRED
Required Parameters
binsSTRING
REQUIREDid:weight_limit:size1xsize2xsize3 (comma seperate more than one bin)
itemsSTRING
REQUIREDid:constraints:weight:size1xsize2xsize3 (comma separate more than one item)
Request Snippet
unirest.post("https://packit4me-bin-packing.p.rapidapi.com/call/raw")
.header("X-RapidAPI-Host", "packit4me-bin-packing.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Content-Type", "application/x-www-form-urlencoded")
.send("bins=0:50:5x5x5")
.send("items=0:0:5:1x2x3,1:0:10:2x4x2")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
Sample Response
Log inSign up

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.post("https://packit4me-bin-packing.p.rapidapi.com/call/raw")
.header("X-RapidAPI-Host", "packit4me-bin-packing.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Content-Type", "application/x-www-form-urlencoded")
.send("bins=0:50:5x5x5")
.send("items=0:0:5:1x2x3,1:0:10:2x4x2")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication