@@ -304,6 +304,68 @@ def create_point():
304304 )
305305
306306
307+ with open (
308+ os .path .join (schemas , "vertex_attribute_names.json" ),
309+ "r" ,
310+ ) as file :
311+ vertex_attribute_names_json = json .load (file )
312+
313+
314+ @routes .route (
315+ vertex_attribute_names_json ["route" ],
316+ methods = vertex_attribute_names_json ["methods" ],
317+ )
318+ def vertex_attribute_names ():
319+
320+ UPLOAD_FOLDER = flask .current_app .config ["UPLOAD_FOLDER" ]
321+ utils_functions .validate_request (flask .request , vertex_attribute_names_json )
322+ file_absolute_path = os .path .join (
323+ UPLOAD_FOLDER , werkzeug .utils .secure_filename (flask .request .json ["filename" ])
324+ )
325+ data = geode_functions .load (
326+ flask .request .json ["input_geode_object" ], file_absolute_path
327+ )
328+ vertex_attribute_names = data .vertex_attribute_manager ().attribute_names ()
329+
330+ return flask .make_response (
331+ {
332+ "vertex_attribute_names" : vertex_attribute_names ,
333+ },
334+ 200 ,
335+ )
336+
337+
338+ with open (
339+ os .path .join (schemas , "polygon_attribute_names.json" ),
340+ "r" ,
341+ ) as file :
342+ polygon_attribute_names_json = json .load (file )
343+
344+
345+ @routes .route (
346+ polygon_attribute_names_json ["route" ],
347+ methods = polygon_attribute_names_json ["methods" ],
348+ )
349+ def polygon_attribute_names ():
350+
351+ UPLOAD_FOLDER = flask .current_app .config ["UPLOAD_FOLDER" ]
352+ utils_functions .validate_request (flask .request , vertex_attribute_names_json )
353+ file_absolute_path = os .path .join (
354+ UPLOAD_FOLDER , werkzeug .utils .secure_filename (flask .request .json ["filename" ])
355+ )
356+ data = geode_functions .load (
357+ flask .request .json ["input_geode_object" ], file_absolute_path
358+ )
359+ polygon_attribute_names = data .polygon_attribute_manager ().attribute_names ()
360+
361+ return flask .make_response (
362+ {
363+ "polygon_attribute_names" : polygon_attribute_names ,
364+ },
365+ 200 ,
366+ )
367+
368+
307369with open (
308370 os .path .join (schemas , "ping.json" ),
309371 "r" ,
0 commit comments