Skip to content

Instantly share code, notes, and snippets.

@ojas
Last active December 28, 2015 06:29
Show Gist options
  • Select an option

  • Save ojas/7457267 to your computer and use it in GitHub Desktop.

Select an option

Save ojas/7457267 to your computer and use it in GitHub Desktop.
lulz
def enum(**enums):
return type('Enum', (), enums)
WORDS = enum(PARTIAL = 1, SANDBOX = 2, SCRAMBLED = 4, LEGACY = 8, PRODUCTION = 16, TRUNCATED = 32)
envs = {
'http://api.dnbdirectapps.com/dev/' : WORDS.SANDBOX + WORDS.PARTIAL + WORDS.SCRAMBLED + WORDS.TRUNCATED,
'http://dnbdirect-sandbox.dnb.com/' : WORDS.SANDBOX + WORDS.SCRAMBLED + WORDS.LEGACY,
'http://dnbdirect-api.dnb.com/' : WORDS.PRODUCTION,
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment