Make a project into a sub-project

I can’t figure this out on my own… How do you make a sub-project via AppleScript?

I’ve got a project. I’ve got another project. I tried

move proj2 to after last project of proj1

but that got an error saying it cant get the last project of proj1. I tried:

set assigned container of proj2 to proj1

but that didn’t seem to change anything.

There is no such thing as a subproject in OmniFocus. OmniFocus does have the notion of folders, which can contain projects, or task groups, which are tasks that contain other tasks.

Colloquially, I read people discussing projects and subprojects in OmniFocus. It turns out that the thing that looks like a sub-project is properly called an “action group.” It appears that what I’ll need to do is to turn my project into an action group and then add the action group to the other project.