* init * test in frontend * copy files * use in cli * better * add desc to sdks * better * fix ts parsing * add docs to ts client * add docs to python client * use script prompt in frontend * regen * use in flow * rm * use in cli, create AGENTS.md instead of cursor rules * remove apply * better * better * simplify cli * more docs * cleaning * update readme * generate cli file * better folder names * fix ts * fix multiline
851 B
851 B
Java
The script must contain a Main public class with a public static main() method:
public class Main {
public static Object main(String name, int count) {
java.util.Map<String, Object> result = new java.util.HashMap<>();
result.put("name", name);
result.put("count", count);
return result;
}
}
Important:
- Class must be named
Main - Method must be
public static Object main(...) - Return type is
Objectorvoid
Maven Dependencies
Add dependencies using comments at the top:
//requirements:
//com.google.code.gson:gson:2.10.1
//org.apache.httpcomponents:httpclient:4.5.14
import com.google.gson.Gson;
public class Main {
public static Object main(String input) {
Gson gson = new Gson();
return gson.fromJson(input, Object.class);
}
}