Regarding your "PS," dare to dream, and I mean that in all seriousness. Esri doesn't even host the code for the API on GitHub, it is just a glorified check box, "we're on GitHub, check." The GitHub page isn't even accurate, in terms of its terminology, i.e., the API is "ArcGIS API for Python" and not "ArcGIS Python API."

At a minimum, I think this is a documentation defect. The documentation simply states:

extent

The extent of the geometry.

Sufficiently vague, it doesn't say an extent object is being returned, but it also doesn't say a tuple of values is being returned.

Beyond the documentation being incomplete, I do think there is a larger code issue. If someone wants an ArcPy Extent object, I think they should be explicit about it and use:

Envelope

An envelope is a rectangle defined by a range of values for each coordinate and attribute. It also has aspatialReferencefield. The fields for the z and m ranges are optional. An empty envelope has no location in space and is defined by the presence of anxminfield, anullvalue, or a "NaN" string.

Overall, I agree with you, whether the ArcGIS API for Python team does remains to be seen.

There is a branching in the ArcGIS environment based on whether arcmap or pro is installed. You would have to examine the actual code to find what is returned in those situations. I think the arcmap/ArcGIS pro environment returns an arcpy Polygon object

This is the type of code line you are looking for in the module you are interested in (an example from one function

....def__geo_interface__(self):"""returns the object as an Feature Collection JSON string"""if HASARCPY:....

Yes it is possible to do this in the script who use the "ArcGIS API for Python". But it was some kind of frustrating to use this great library to create some geometry-stuff and it worked in an environment and in the other environment it does not work, after some time debugging you can find the answer..... But not in the documentation, or?

On the other hand it would really helpful if the answer is syntactically the same.

Regarding your "PS," dare to dream, and I mean that in all seriousness. Esri doesn't even host the code for the API on GitHub, it is just a glorified check box, "we're on GitHub, check." The GitHub page isn't even accurate, in terms of its terminology, i.e., the API is "ArcGIS API for Python" and not "ArcGIS Python API."

At a minimum, I think this is a documentation defect. The documentation simply states:

extent

The extent of the geometry.

Sufficiently vague, it doesn't say an extent object is being returned, but it also doesn't say a tuple of values is being returned.

Beyond the documentation being incomplete, I do think there is a larger code issue. If someone wants an ArcPy Extent object, I think they should be explicit about it and use:

Envelope

An envelope is a rectangle defined by a range of values for each coordinate and attribute. It also has aspatialReferencefield. The fields for the z and m ranges are optional. An empty envelope has no location in space and is defined by the presence of anxminfield, anullvalue, or a "NaN" string.

Overall, I agree with you, whether the ArcGIS API for Python team does remains to be seen.