Skip to content

Instantly share code, notes, and snippets.

@allenmichael
Created September 9, 2017 00:20
Show Gist options
  • Save allenmichael/15729ad4531597021f7348d47c43d864 to your computer and use it in GitHub Desktop.
Save allenmichael/15729ad4531597021f7348d47c43d864 to your computer and use it in GitHub Desktop.
package com.amsxbg;
import com.box.sdk.*;
import java.io.FileReader;
import java.io.Reader;
public class App {
public static void main( String[] args ) {
try(Reader reader = new FileReader("src/config/config.json")) {
BoxConfig boxConfig = BoxConfig.readFrom(reader);
BoxDeveloperEditionAPIConnection api = BoxDeveloperEditionAPIConnection.getAppEnterpriseConnection(boxConfig);
BoxFolder folder = new BoxFolder(api, "34250344135");
Metadata md = folder.createMetadata("CLI_NEWER_TEMPLATE", "enterprise", new Metadata().add("/TVFREEZE", "frozen"));
System.out.println(md.getID());
} catch (java.io.IOException e) {
e.printStackTrace();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment