Pre-requisites

Necessary preparation for integration with BSG

Whitelisting of agency system's IP address to access BookingSG staging server

BookingSG staging server is protected by IP whitelisting. In order for agency servers / development team to access the staging server and our full API listings, their respective public IPs need to be whitelisted first. For whitelisting request, send an email to support@booking.gov.sg.

There is no whitelisting for our production server.

Setup of private keys

You will need to generate two PKCS8 key pair (one for production access, one for non-production access), and pass to BSG only the public keys (.crt files)

  • Our mail hygiene check might block the public key due to the file extension, hence it's advisable to rename your public key to a .txt file extension first, before performing a password protect zip. Another alternative is to send us the public key in microsoft word document protected by password.Make sure to name your keys so that we can differentiate which is the one used for production and non production.

Generating a PKCS8 keypair

# Generate key pair
openssl genrsa -out keypair.pem 2048

# Extracting the public/private key. Pass BookingSG ONLY the public key
openssl rsa -in keypair.pem -pubout -out publickey.crt
openssl rsa -in keypair.pem -out private.key

# Generating an encrypted private key (optional)
openssl pkcs8 -topk8 -inform PEM -outform PEM -in keypair.pem -out pkcs8.key
openssl pkcs12 -export -out keystore.pfx -inkey keypair.pem -in publickey.crt -nocerts
  • Only send us the public keys, do not send us your private keys or pass phrase. Once we receive your public keys, we will proceed with the system setup and get back to you within 5 working days.

Last updated