About the Binary Converter API

API Version: 1.9

The Binary Converter allows you to convert numbers between different bases: binary, octal, decimal, and hexadecimal.

This is the API for the Binary Converter.

Endpoints

GET
https://networkcalc.com/api/binary/{number}

Convert numbers

. Converts numbers between binary, octal, decimal, and hexadecimal.

Parameters

{number}

The number to convert from. May be specified as a binary, octal, decimal, or hexadecimal number.

Example: https://networkcalc.com/api/binary/00001010

from

(Optional) The radix (base) to convert from.

Values: 2,8,10,16

Example: https://networkcalc.com/api/binary/1e7d6d?from=16

to

(Optional) The radix (base) to convert to.

Values: 2,8,10,16

Example: https://networkcalc.com/api/binary/00001010?to=16

Response Codes

200
OK - Success.
400
NO_NUMBER_SPECIFIED - The {number} parameter is missing.
400
INVALID_NUMBER_FORMAT - The {number} parameter is malformed.
400
INVALID_FROM_BASE - The from parameter is is not valid.
400
INVALID_TO_BASE - The to parameter is not valid.

Response Formats

ConverterResponse

{
  "status": "[string] The status of the request.",
  "from": "[string] The number to convert from.",
  "to": "[string] The converted number or null."
}