Created
November 1, 2024 13:11
-
-
Save RalucaNicola/76f5613209a008d17e488b128b28fcfe to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| publish_params_khaled = { | |
| "type": "geojson", | |
| "name": "brian_repro", | |
| "useBulkInserts": True, | |
| "sourceUrl": "", | |
| "targetSR": { "wkid": 102100, "latestWkid": 3857 }, | |
| "editorTrackingInfo": { | |
| "enableEditorTracking": False, | |
| "enableOwnershipAccessControl": False, | |
| "allowOthersToQuery": True, | |
| "allowOthersToUpdate": True, | |
| "allowOthersToDelete": False, | |
| "allowAnonymousToQuery": True, | |
| "allowAnonymousToUpdate": True, | |
| "allowAnonymousToDelete": True | |
| }, | |
| "streamFeatures": True, | |
| "convertLongToDecimal": True, | |
| "layers": [ | |
| { | |
| "currentVersion": 11.2, | |
| "id": 0, | |
| "name": "brian_repro_polygons", | |
| "type": "Feature Layer", | |
| "displayField": "", | |
| "description": "", | |
| "copyrightText": "", | |
| "defaultVisibility": True, | |
| "relationships": [], | |
| "isDataVersioned": False, | |
| "supportsAppend": True, | |
| "supportsCalculate": True, | |
| "supportsASyncCalculate": True, | |
| "supportsTruncate": False, | |
| "supportsAttachmentsByUploadId": True, | |
| "supportsAttachmentsResizing": True, | |
| "supportsRollbackOnFailureParameter": True, | |
| "supportsStatistics": True, | |
| "supportsExceedsLimitStatistics": True, | |
| "supportsAdvancedQueries": True, | |
| "supportsValidateSql": True, | |
| "supportsCoordinatesQuantization": True, | |
| "supportsLayerOverrides": True, | |
| "supportsTilesAndBasicQueriesMode": True, | |
| "supportsFieldDescriptionProperty": True, | |
| "supportsQuantizationEditMode": True, | |
| "supportsApplyEditsWithGlobalIds": False, | |
| "supportsMultiScaleGeometry": True, | |
| "supportsReturningQueryGeometry": True, | |
| "hasGeometryProperties": True, | |
| "geometryProperties": { | |
| "shapeAreaFieldName": "Shape__Area", | |
| "shapeLengthFieldName": "Shape__Length" | |
| }, | |
| "advancedQueryCapabilities": { | |
| "supportsPagination": True, | |
| "supportsQueryAttachmentsCountOnly": True, | |
| "supportsPaginationOnAggregatedQueries": True, | |
| "supportsQueryRelatedPagination": True, | |
| "supportsQueryWithDistance": True, | |
| "supportsReturningQueryExtent": True, | |
| "supportsStatistics": True, | |
| "supportsOrderBy": True, | |
| "supportsDistinct": True, | |
| "supportsQueryWithResultType": True, | |
| "supportsSqlExpression": True, | |
| "supportsTimeRelation": True, | |
| "supportsAdvancedQueryRelated": True, | |
| "supportsCountDistinct": True, | |
| "supportsPercentileStatistics": True, | |
| "supportsApproxPercentileStatistics": True, | |
| "supportsSpatialAggregationStatistics": True, | |
| "supportsTrueCurve": True, | |
| "supportedSpatialAggregationStatistics": [ | |
| "EnvelopeAggregate", | |
| "CentroidAggregate", | |
| "ConvexHullAggregate" | |
| ], | |
| "supportsReturningGeometryCentroid": True, | |
| "supportsReturningGeometryEnvelope": True, | |
| "supportsReturningGeometryProperties": True, | |
| "supportsQueryWithDatumTransformation": True, | |
| "supportsCurrentUserQueries": True, | |
| "supportsHavingClause": True, | |
| "supportsOutFieldSQLExpression": True, | |
| "supportsMaxRecordCountFactor": True, | |
| "supportsTopFeaturesQuery": True, | |
| "supportsDisjointSpatialRel": True, | |
| "supportsQueryWithCacheHint": True, | |
| "supportedOperationsWithCacheHint": [ | |
| "query", | |
| "queryTopFilter", | |
| "queryAnalytics", | |
| "queryAttachments", | |
| "queryRelated", | |
| "queryBins" | |
| ], | |
| "supportsQueryAnalytic": True, | |
| "supportsDefaultSR": True, | |
| "supportsFullTextSearch": True, | |
| "supportsFullTextAccentSensitivity": True, | |
| "supportsFullTextStopWords": True | |
| }, | |
| "advancedQueryAnalyticCapabilities": { | |
| "supportsLinearRegression": True, | |
| "supportsAsync": True, | |
| "supportsPercentileAnalytic": True | |
| }, | |
| "advancedEditingCapabilities": { | |
| "supportedSqlFormatsInCalculate": ["standard"], | |
| "supportsAsyncApplyEdits": True, | |
| "supportsReturnEditResults": True, | |
| "supportsApplyEditsbyUploadID": True, | |
| "supportedApplyEditsUploadIDFormats": "JSON" | |
| }, | |
| "infoInEstimates": ["extent", "count"], | |
| "useStandardizedQueries": False, | |
| "geometryType": "esriGeometryPolygon", | |
| "minScale": 0, | |
| "maxScale": 0, | |
| "extent": { | |
| "xmin": -9982315.1832368243, | |
| "ymin": 5327527.1198434364, | |
| "xmax": -9982054.8069478571, | |
| "ymax": 5327825.6487744907, | |
| "spatialReference": { "wkid": 102100, "latestWkid": 3857 } | |
| }, | |
| "drawingInfo": { | |
| "renderer": { | |
| "type": "simple", | |
| "symbol": { | |
| "type": "esriSFS", | |
| "style": "esriSFSSolid", | |
| "color": [76, 129, 205, 191], | |
| "outline": { | |
| "type": "esriSLS", | |
| "style": "esriSLSSolid", | |
| "color": [0, 0, 0, 255], | |
| "width": 0.75 | |
| } | |
| } | |
| }, | |
| "transparency": 0, | |
| "labelingInfo": None | |
| }, | |
| "allowGeometryUpdates": True, | |
| "supportedCurveTypes": ["esriGeometryCircularArc"], | |
| "allowTrueCurvesUpdates": False, | |
| "onlyAllowTrueCurveUpdatesByTrueCurveClients": False, | |
| "hasAttachments": False, | |
| "htmlPopupType": "", | |
| "hasM": False, | |
| "hasZ": False, | |
| "objectIdField": "ObjectId", | |
| "globalIdField": "", | |
| "typeIdField": "", | |
| "estimatedRecordCount": 3, | |
| "collation": { | |
| "locale": "en-US", | |
| "caseSensitive": False, | |
| "accentSensitive": True | |
| }, | |
| "fields": [ | |
| { | |
| "name": "project_or_policy", | |
| "type": "esriFieldTypeString", | |
| "alias": "project_or_policy", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "diagram_name", | |
| "type": "esriFieldTypeString", | |
| "alias": "diagram_name", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "color", | |
| "type": "esriFieldTypeString", | |
| "alias": "color", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "diagram_id", | |
| "type": "esriFieldTypeInteger", | |
| "alias": "diagram_id", | |
| "sqlType": "sqlTypeInteger", | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "tag_codes", | |
| "type": "esriFieldTypeString", | |
| "alias": "tag_codes", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "start_date", | |
| "type": "esriFieldTypeDate", | |
| "alias": "start_date", | |
| "sqlType": "sqlTypeDate", | |
| "length": 0, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None, | |
| "precision": 1 | |
| }, | |
| { | |
| "name": "end_date", | |
| "type": "esriFieldTypeDate", | |
| "alias": "end_date", | |
| "sqlType": "sqlTypeDate", | |
| "length": 0, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None, | |
| "precision": 1 | |
| }, | |
| { | |
| "name": "notes", | |
| "type": "esriFieldTypeString", | |
| "alias": "notes", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "grid_location", | |
| "type": "esriFieldTypeString", | |
| "alias": "grid_location", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "system_name", | |
| "type": "esriFieldTypeString", | |
| "alias": "system_name", | |
| "sqlType": "sqlTypeNVarchar", | |
| "length": 4000, | |
| "Noneable": True, | |
| "editable": True, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "ObjectId", | |
| "type": "esriFieldTypeOID", | |
| "alias": "ObjectId", | |
| "sqlType": "sqlTypeOther", | |
| "Noneable": False, | |
| "editable": False, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "Shape__Area", | |
| "type": "esriFieldTypeDouble", | |
| "alias": "Shape__Area", | |
| "sqlType": "sqlTypeDouble", | |
| "Noneable": True, | |
| "editable": False, | |
| "domain": None, | |
| "defaultValue": None | |
| }, | |
| { | |
| "name": "Shape__Length", | |
| "type": "esriFieldTypeDouble", | |
| "alias": "Shape__Length", | |
| "sqlType": "sqlTypeDouble", | |
| "Noneable": True, | |
| "editable": False, | |
| "domain": None, | |
| "defaultValue": None | |
| } | |
| ], | |
| "indexes": [ | |
| { | |
| "name": "Shape__Area_Index", | |
| "fields": "Shape__Area", | |
| "isAscending": True, | |
| "isUnique": False, | |
| "description": "", | |
| "indexType": "Attribute" | |
| }, | |
| { | |
| "name": "Shape__Length_Index", | |
| "fields": "Shape__Length", | |
| "isAscending": True, | |
| "isUnique": False, | |
| "description": "", | |
| "indexType": "Attribute" | |
| } | |
| ], | |
| "dateFieldsTimeReference": { | |
| "timeZone": "UTC", | |
| "respectsDaylightSaving": False | |
| }, | |
| "preferredTimeReference": None, | |
| "types": [], | |
| "templates": [], | |
| "supportedQueryFormats": "JSON, geoJSON, PBF", | |
| "supportedAppendFormats": "sqlite,geoPackage,shapefile,filegdb,featureCollection,geojson,csv,excel,jsonl,featureService,pbf", | |
| "supportedAppendSourceFilterFormats": "sqlite,geoPackage,shapefile,filegdb,featureService", | |
| "supportedExportFormats": "csv,shapefile,sqlite,geoPackage,filegdb,featureCollection,geojson,kml,excel", | |
| "supportedConvertFileFormats": "JSON,PBF", | |
| "supportedConvertContentFormats": "LayerEditCollection,FeatureCollection", | |
| "supportedSpatialRelationships": [ | |
| "esriSpatialRelIntersects", | |
| "esriSpatialRelContains", | |
| "esriSpatialRelCrosses", | |
| "esriSpatialRelEnvelopeIntersects", | |
| "esriSpatialRelIndexIntersects", | |
| "esriSpatialRelOverlaps", | |
| "esriSpatialRelTouches", | |
| "esriSpatialRelWithin", | |
| "esriSpatialRelDisjoint", | |
| "esriSpatialRelRelation" | |
| ], | |
| "supportedContingentValuesFormats": "JSON, PBF", | |
| "supportedSyncDataOptions": 260, | |
| "hasStaticData": False, | |
| "maxRecordCount": -1, | |
| "standardMaxRecordCount": 4000, | |
| "standardMaxRecordCountNoGeometry": 32000, | |
| "tileMaxRecordCount": 4000, | |
| "maxRecordCountFactor": 1, | |
| "capabilities": "Create,Delete,Query,Update,Editing" | |
| } | |
| ] | |
| } | |
| feature_layer_item = geojson_item.publish(publish_parameters = publish_params_khaled) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment