#' List ChangeRequestDetails
#'
#' This function returns a dataframe or json object of ChangeRequestDetails
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ChangeRequestDetails. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ChangeRequestDetails.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ChangeRequestDetail') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of ChangeRequestDetails
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listChangeRequestDetails <- function(searchConditionsList = NULL, ChangeRequestDetailID = F, ChangeRequestID = F, CreatedTime = F, FieldName = F, ModifiedTime = F, OriginalValue = F, RequestedTime = F, RequestedValue = F, SourceID = F, Status = F, UserIDApprover = F, UserIDCreatedBy = F, UserIDModifiedBy = F, UserIDRequestedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ChangeRequestDetail", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a ChangeRequestDetail
#'
#' This function returns a dataframe or json object of a ChangeRequestDetail
#' @param ChangeRequestDetailID The ID of the ChangeRequestDetail to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ChangeRequestDetail. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ChangeRequestDetail.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ChangeRequestDetail') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of ChangeRequestDetail
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getChangeRequestDetail <- function(ChangeRequestDetailID, ChangeRequestID = F, CreatedTime = F, FieldName = F, ModifiedTime = F, OriginalValue = F, RequestedTime = F, RequestedValue = F, SourceID = F, Status = F, UserIDApprover = F, UserIDCreatedBy = F, UserIDModifiedBy = F, UserIDRequestedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "ChangeRequestDetailID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ChangeRequestDetail", objectId = ChangeRequestDetailID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a ChangeRequestDetail
#'
#' This function deletes a ChangeRequestDetail
#' @param ChangeRequestDetailID The ID of the ChangeRequestDetail to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The ChangeRequestDetailID of the deleted ChangeRequestDetail.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteChangeRequestDetail <- function(ChangeRequestDetailID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ChangeRequestDetail", objectId = ChangeRequestDetailID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a ChangeRequestDetail
#'
#' This function creates a ChangeRequestDetail
#' @param fieldNames The field values to give the created ChangeRequestDetail. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created ChangeRequestDetail
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createChangeRequestDetail <- function(ChangeRequestID = NULL, FieldName = NULL, OriginalValue = NULL, RequestedTime = NULL, RequestedValue = NULL, SourceID = NULL, Status = NULL, UserIDApprover = NULL, UserIDRequestedBy = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ChangeRequestDetail", body = list(DataObject = body), searchFields = append("ChangeRequestDetailID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a ChangeRequestDetail
#'
#' This function modifies a ChangeRequestDetail
#' @param fieldNames The field values to give the modified ChangeRequestDetail. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified ChangeRequestDetail
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyChangeRequestDetail <- function(ChangeRequestDetailID, ChangeRequestID = NULL, FieldName = NULL, OriginalValue = NULL, RequestedTime = NULL, RequestedValue = NULL, SourceID = NULL, Status = NULL, UserIDApprover = NULL, UserIDRequestedBy = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ChangeRequestDetail", objectId = ChangeRequestDetailID, body = list(DataObject = body), searchFields = append("ChangeRequestDetailID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List ChangeRequests
#'
#' This function returns a dataframe or json object of ChangeRequests
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ChangeRequests. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ChangeRequests.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ChangeRequest') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of ChangeRequests
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listChangeRequests <- function(searchConditionsList = NULL, Area = F, ChangeRequestID = F, CreatedTime = F, EntityID = F, ModifiedTime = F, NameID = F, SchoolYearID = F, Status = F, StatusCode = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ChangeRequest", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a ChangeRequest
#'
#' This function returns a dataframe or json object of a ChangeRequest
#' @param ChangeRequestID The ID of the ChangeRequest to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ChangeRequest. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ChangeRequest.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ChangeRequest') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of ChangeRequest
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getChangeRequest <- function(ChangeRequestID, Area = F, CreatedTime = F, EntityID = F, ModifiedTime = F, NameID = F, SchoolYearID = F, Status = F, StatusCode = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "ChangeRequestID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ChangeRequest", objectId = ChangeRequestID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a ChangeRequest
#'
#' This function deletes a ChangeRequest
#' @param ChangeRequestID The ID of the ChangeRequest to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The ChangeRequestID of the deleted ChangeRequest.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteChangeRequest <- function(ChangeRequestID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ChangeRequest", objectId = ChangeRequestID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a ChangeRequest
#'
#' This function creates a ChangeRequest
#' @param fieldNames The field values to give the created ChangeRequest. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created ChangeRequest
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createChangeRequest <- function(Area = NULL, EntityID = NULL, NameID = NULL, SchoolYearID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ChangeRequest", body = list(DataObject = body), searchFields = append("ChangeRequestID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a ChangeRequest
#'
#' This function modifies a ChangeRequest
#' @param fieldNames The field values to give the modified ChangeRequest. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified ChangeRequest
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyChangeRequest <- function(ChangeRequestID, Area = NULL, EntityID = NULL, NameID = NULL, SchoolYearID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ChangeRequest", objectId = ChangeRequestID, body = list(DataObject = body), searchFields = append("ChangeRequestID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List ChangeRequestDetailApprovals
#'
#' This function returns a dataframe or json object of ChangeRequestDetailApprovals
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ChangeRequestDetailApprovals. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ChangeRequestDetailApprovals.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ChangeRequestDetailApproval') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of ChangeRequestDetailApprovals
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listChangeRequestDetailApprovals <- function(searchConditionsList = NULL, ChangeRequestDetailApprovalID = F, ChangeRequestDetailID = F, Comment = F, CreatedTime = F, ModifiedTime = F, Status = F, UserIDApprover = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ChangeRequestDetailApproval", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a ChangeRequestDetailApproval
#'
#' This function returns a dataframe or json object of a ChangeRequestDetailApproval
#' @param ChangeRequestDetailApprovalID The ID of the ChangeRequestDetailApproval to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ChangeRequestDetailApproval. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ChangeRequestDetailApproval.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ChangeRequestDetailApproval') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of ChangeRequestDetailApproval
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getChangeRequestDetailApproval <- function(ChangeRequestDetailApprovalID, ChangeRequestDetailID = F, Comment = F, CreatedTime = F, ModifiedTime = F, Status = F, UserIDApprover = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "ChangeRequestDetailApprovalID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ChangeRequestDetailApproval", objectId = ChangeRequestDetailApprovalID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a ChangeRequestDetailApproval
#'
#' This function deletes a ChangeRequestDetailApproval
#' @param ChangeRequestDetailApprovalID The ID of the ChangeRequestDetailApproval to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The ChangeRequestDetailApprovalID of the deleted ChangeRequestDetailApproval.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteChangeRequestDetailApproval <- function(ChangeRequestDetailApprovalID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ChangeRequestDetailApproval", objectId = ChangeRequestDetailApprovalID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a ChangeRequestDetailApproval
#'
#' This function creates a ChangeRequestDetailApproval
#' @param fieldNames The field values to give the created ChangeRequestDetailApproval. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created ChangeRequestDetailApproval
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createChangeRequestDetailApproval <- function(ChangeRequestDetailID = NULL, Comment = NULL, Status = NULL, UserIDApprover = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ChangeRequestDetailApproval", body = list(DataObject = body), searchFields = append("ChangeRequestDetailApprovalID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a ChangeRequestDetailApproval
#'
#' This function modifies a ChangeRequestDetailApproval
#' @param fieldNames The field values to give the modified ChangeRequestDetailApproval. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified ChangeRequestDetailApproval
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyChangeRequestDetailApproval <- function(ChangeRequestDetailApprovalID, ChangeRequestDetailID = NULL, Comment = NULL, Status = NULL, UserIDApprover = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ChangeRequestDetailApproval", objectId = ChangeRequestDetailApprovalID, body = list(DataObject = body), searchFields = append("ChangeRequestDetailApprovalID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List FamilyConfigEntityGroupYears
#'
#' This function returns a dataframe or json object of FamilyConfigEntityGroupYears
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyConfigEntityGroupYears. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyConfigEntityGroupYears.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyConfigEntityGroupYear') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of FamilyConfigEntityGroupYears
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilyConfigEntityGroupYears <- function(searchConditionsList = NULL, CareerPlanSignatureOption = F, CareerPlanSignatureStatement = F, ChangeRequestFamilyEmail = F, ChangeRequestFamilyPhone = F, ChangeRequestStudentEmail = F, ConfigEntityGroupYearID = F, ConfigEntityGroupYearIDClonedFrom = F, CreatedTime = F, DefaultFeeManagementOnlinePaymentAccess = F, DefaultFoodServiceOnlinePaymentAccess = F, DisplayAbsencesAndTardies = F, DisplayAssignments = F, DisplayCalendarComments = F, DisplayCalendarEvents = F, DisplayDistrictActivityEvents = F, DisplayStudentActivityEvents = F, EmailTypeIDToDisplayFamilyStudentAccess = F, EndorsementSignatureOption = F, EndorsementSignatureStatement = F, EntityGroupKey = F, EntityID = F, FamilyAccessAccountInfoEmailBody = F, FamilyAccessAccountInfoEmailIncludeResetPasswordText = F, FamilyAccessAccountInfoEmailSubject = F, FamilyAccessCareerPlanDisplayShowDroppedCourses = F, FamilyAccessDisplayAssignmentAverages = F, FamilyAccessDisplayGPA = F, FamilyAccessDisplayGradeBucketsAfterEndDate = F, FamilyAccessDisplayHonorRoll = F, FamilyAccessDisplayLockerCombination = F, FamilyAccessDisplayLockerNumber = F, FamilyAccessDisplayOnlyCurrentAndCompleteGrades = F, FamilyAccessDisplayOnlyCurrentMissingAssignments = F, FamilyAccessDisplayStudentRank = F, FamilyStudentAccessDisplayTeacherEmail = F, FamilyStudentAccessDisplayTeacherPhoneNumber = F, HideScheduleMessage = F, HideSchedulePriorToCalendarDays = F, IsFamilyInformationApprovalWorkflowUpdated = F, IsStudentInformationApprovalWorkflowUpdated = F, ModifiedTime = F, PhoneTypeIDToDisplayFamilyStudentAccess = F, RankMethodIDFamilyAccessReportCardStudent = F, ReportCardStudentRankDisplay = F, SchoolYearID = F, StaffNameDisplayType = F, TrackFamilyAccessUsageHistory = F, TrackStudentAccessUsageHistory = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ConfigEntityGroupYear", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a FamilyConfigEntityGroupYear
#'
#' This function returns a dataframe or json object of a FamilyConfigEntityGroupYear
#' @param FamilyConfigEntityGroupYearID The ID of the FamilyConfigEntityGroupYear to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyConfigEntityGroupYear. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyConfigEntityGroupYear.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyConfigEntityGroupYear') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of FamilyConfigEntityGroupYear
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamilyConfigEntityGroupYear <- function(FamilyConfigEntityGroupYearID, CareerPlanSignatureOption = F, CareerPlanSignatureStatement = F, ChangeRequestFamilyEmail = F, ChangeRequestFamilyPhone = F, ChangeRequestStudentEmail = F, ConfigEntityGroupYearID = F, ConfigEntityGroupYearIDClonedFrom = F, CreatedTime = F, DefaultFeeManagementOnlinePaymentAccess = F, DefaultFoodServiceOnlinePaymentAccess = F, DisplayAbsencesAndTardies = F, DisplayAssignments = F, DisplayCalendarComments = F, DisplayCalendarEvents = F, DisplayDistrictActivityEvents = F, DisplayStudentActivityEvents = F, EmailTypeIDToDisplayFamilyStudentAccess = F, EndorsementSignatureOption = F, EndorsementSignatureStatement = F, EntityGroupKey = F, EntityID = F, FamilyAccessAccountInfoEmailBody = F, FamilyAccessAccountInfoEmailIncludeResetPasswordText = F, FamilyAccessAccountInfoEmailSubject = F, FamilyAccessCareerPlanDisplayShowDroppedCourses = F, FamilyAccessDisplayAssignmentAverages = F, FamilyAccessDisplayGPA = F, FamilyAccessDisplayGradeBucketsAfterEndDate = F, FamilyAccessDisplayHonorRoll = F, FamilyAccessDisplayLockerCombination = F, FamilyAccessDisplayLockerNumber = F, FamilyAccessDisplayOnlyCurrentAndCompleteGrades = F, FamilyAccessDisplayOnlyCurrentMissingAssignments = F, FamilyAccessDisplayStudentRank = F, FamilyStudentAccessDisplayTeacherEmail = F, FamilyStudentAccessDisplayTeacherPhoneNumber = F, HideScheduleMessage = F, HideSchedulePriorToCalendarDays = F, IsFamilyInformationApprovalWorkflowUpdated = F, IsStudentInformationApprovalWorkflowUpdated = F, ModifiedTime = F, PhoneTypeIDToDisplayFamilyStudentAccess = F, RankMethodIDFamilyAccessReportCardStudent = F, ReportCardStudentRankDisplay = F, SchoolYearID = F, StaffNameDisplayType = F, TrackFamilyAccessUsageHistory = F, TrackStudentAccessUsageHistory = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyConfigEntityGroupYearID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ConfigEntityGroupYear", objectId = FamilyConfigEntityGroupYearID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a FamilyConfigEntityGroupYear
#'
#' This function deletes a FamilyConfigEntityGroupYear
#' @param FamilyConfigEntityGroupYearID The ID of the FamilyConfigEntityGroupYear to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyConfigEntityGroupYearID of the deleted FamilyConfigEntityGroupYear.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamilyConfigEntityGroupYear <- function(FamilyConfigEntityGroupYearID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ConfigEntityGroupYear", objectId = FamilyConfigEntityGroupYearID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a FamilyConfigEntityGroupYear
#'
#' This function creates a FamilyConfigEntityGroupYear
#' @param fieldNames The field values to give the created FamilyConfigEntityGroupYear. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created FamilyConfigEntityGroupYear
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamilyConfigEntityGroupYear <- function(CareerPlanSignatureOption = NULL, CareerPlanSignatureStatement = NULL, ChangeRequestFamilyEmail = NULL, ChangeRequestFamilyPhone = NULL, ChangeRequestStudentEmail = NULL, ConfigEntityGroupYearIDClonedFrom = NULL, DefaultFeeManagementOnlinePaymentAccess = NULL, DefaultFoodServiceOnlinePaymentAccess = NULL, DisplayAbsencesAndTardies = NULL, DisplayAssignments = NULL, DisplayCalendarComments = NULL, DisplayCalendarEvents = NULL, DisplayDistrictActivityEvents = NULL, DisplayStudentActivityEvents = NULL, EmailTypeIDToDisplayFamilyStudentAccess = NULL, EndorsementSignatureOption = NULL, EndorsementSignatureStatement = NULL, EntityGroupKey = NULL, EntityID = NULL, FamilyAccessAccountInfoEmailBody = NULL, FamilyAccessAccountInfoEmailIncludeResetPasswordText = NULL, FamilyAccessAccountInfoEmailSubject = NULL, FamilyAccessCareerPlanDisplayShowDroppedCourses = NULL, FamilyAccessDisplayAssignmentAverages = NULL, FamilyAccessDisplayGPA = NULL, FamilyAccessDisplayGradeBucketsAfterEndDate = NULL, FamilyAccessDisplayHonorRoll = NULL, FamilyAccessDisplayLockerCombination = NULL, FamilyAccessDisplayLockerNumber = NULL, FamilyAccessDisplayOnlyCurrentAndCompleteGrades = NULL, FamilyAccessDisplayOnlyCurrentMissingAssignments = NULL, FamilyAccessDisplayStudentRank = NULL, FamilyStudentAccessDisplayTeacherEmail = NULL, FamilyStudentAccessDisplayTeacherPhoneNumber = NULL, HideScheduleMessage = NULL, HideSchedulePriorToCalendarDays = NULL, PhoneTypeIDToDisplayFamilyStudentAccess = NULL, RankMethodIDFamilyAccessReportCardStudent = NULL, ReportCardStudentRankDisplay = NULL, SchoolYearID = NULL, StaffNameDisplayType = NULL, TrackFamilyAccessUsageHistory = NULL, TrackStudentAccessUsageHistory = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ConfigEntityGroupYear", body = list(DataObject = body), searchFields = append("ConfigEntityGroupYearID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a FamilyConfigEntityGroupYear
#'
#' This function modifies a FamilyConfigEntityGroupYear
#' @param fieldNames The field values to give the modified FamilyConfigEntityGroupYear. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified FamilyConfigEntityGroupYear
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamilyConfigEntityGroupYear <- function(ConfigEntityGroupYearID, CareerPlanSignatureOption = NULL, CareerPlanSignatureStatement = NULL, ChangeRequestFamilyEmail = NULL, ChangeRequestFamilyPhone = NULL, ChangeRequestStudentEmail = NULL, ConfigEntityGroupYearIDClonedFrom = NULL, DefaultFeeManagementOnlinePaymentAccess = NULL, DefaultFoodServiceOnlinePaymentAccess = NULL, DisplayAbsencesAndTardies = NULL, DisplayAssignments = NULL, DisplayCalendarComments = NULL, DisplayCalendarEvents = NULL, DisplayDistrictActivityEvents = NULL, DisplayStudentActivityEvents = NULL, EmailTypeIDToDisplayFamilyStudentAccess = NULL, EndorsementSignatureOption = NULL, EndorsementSignatureStatement = NULL, EntityGroupKey = NULL, EntityID = NULL, FamilyAccessAccountInfoEmailBody = NULL, FamilyAccessAccountInfoEmailIncludeResetPasswordText = NULL, FamilyAccessAccountInfoEmailSubject = NULL, FamilyAccessCareerPlanDisplayShowDroppedCourses = NULL, FamilyAccessDisplayAssignmentAverages = NULL, FamilyAccessDisplayGPA = NULL, FamilyAccessDisplayGradeBucketsAfterEndDate = NULL, FamilyAccessDisplayHonorRoll = NULL, FamilyAccessDisplayLockerCombination = NULL, FamilyAccessDisplayLockerNumber = NULL, FamilyAccessDisplayOnlyCurrentAndCompleteGrades = NULL, FamilyAccessDisplayOnlyCurrentMissingAssignments = NULL, FamilyAccessDisplayStudentRank = NULL, FamilyStudentAccessDisplayTeacherEmail = NULL, FamilyStudentAccessDisplayTeacherPhoneNumber = NULL, HideScheduleMessage = NULL, HideSchedulePriorToCalendarDays = NULL, PhoneTypeIDToDisplayFamilyStudentAccess = NULL, RankMethodIDFamilyAccessReportCardStudent = NULL, ReportCardStudentRankDisplay = NULL, SchoolYearID = NULL, StaffNameDisplayType = NULL, TrackFamilyAccessUsageHistory = NULL, TrackStudentAccessUsageHistory = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ConfigEntityGroupYear", objectId = ConfigEntityGroupYearID, body = list(DataObject = body), searchFields = append("ConfigEntityGroupYearID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List FamilyConfigSystems
#'
#' This function returns a dataframe or json object of FamilyConfigSystems
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyConfigSystems. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyConfigSystems.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyConfigSystem') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of FamilyConfigSystems
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilyConfigSystems <- function(searchConditionsList = NULL, AddressValidationMessage = F, AllowFamilyAccessDefault = F, AllowOutOfRangeAddressesToSubmit = F, AutoGenerateSecurityUser = F, ConfigSystemID = F, CreatedTime = F, EnableAddressValidation = F, EnableNewStudentEnrollment = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ConfigSystem", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a FamilyConfigSystem
#'
#' This function returns a dataframe or json object of a FamilyConfigSystem
#' @param FamilyConfigSystemID The ID of the FamilyConfigSystem to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyConfigSystem. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyConfigSystem.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyConfigSystem') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of FamilyConfigSystem
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamilyConfigSystem <- function(FamilyConfigSystemID, AddressValidationMessage = F, AllowFamilyAccessDefault = F, AllowOutOfRangeAddressesToSubmit = F, AutoGenerateSecurityUser = F, ConfigSystemID = F, CreatedTime = F, EnableAddressValidation = F, EnableNewStudentEnrollment = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyConfigSystemID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ConfigSystem", objectId = FamilyConfigSystemID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a FamilyConfigSystem
#'
#' This function deletes a FamilyConfigSystem
#' @param FamilyConfigSystemID The ID of the FamilyConfigSystem to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyConfigSystemID of the deleted FamilyConfigSystem.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamilyConfigSystem <- function(FamilyConfigSystemID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ConfigSystem", objectId = FamilyConfigSystemID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a FamilyConfigSystem
#'
#' This function creates a FamilyConfigSystem
#' @param fieldNames The field values to give the created FamilyConfigSystem. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created FamilyConfigSystem
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamilyConfigSystem <- function(AddressValidationMessage = NULL, AllowFamilyAccessDefault = NULL, AllowOutOfRangeAddressesToSubmit = NULL, AutoGenerateSecurityUser = NULL, EnableAddressValidation = NULL, EnableNewStudentEnrollment = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ConfigSystem", body = list(DataObject = body), searchFields = append("ConfigSystemID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a FamilyConfigSystem
#'
#' This function modifies a FamilyConfigSystem
#' @param fieldNames The field values to give the modified FamilyConfigSystem. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified FamilyConfigSystem
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamilyConfigSystem <- function(ConfigSystemID, AddressValidationMessage = NULL, AllowFamilyAccessDefault = NULL, AllowOutOfRangeAddressesToSubmit = NULL, AutoGenerateSecurityUser = NULL, EnableAddressValidation = NULL, EnableNewStudentEnrollment = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ConfigSystem", objectId = ConfigSystemID, body = list(DataObject = body), searchFields = append("ConfigSystemID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List TempFamilyGuardians
#'
#' This function returns a dataframe or json object of TempFamilyGuardians
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given TempFamilyGuardians. Defaults to FALSE for all return fields which, for convenience, returns all fields for the TempFamilyGuardians.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('TempFamilyGuardian') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of TempFamilyGuardians
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listTempFamilyGuardians <- function(searchConditionsList = NULL, CreatedTime = F, GuardianNameID = F, GuardianNameLFM = F, IsFamilyAccessUser = F, ModifiedTime = F, TempFamilyGuardianID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "TempFamilyGuardian", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a TempFamilyGuardian
#'
#' This function returns a dataframe or json object of a TempFamilyGuardian
#' @param TempFamilyGuardianID The ID of the TempFamilyGuardian to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given TempFamilyGuardian. Defaults to FALSE for all return fields which, for convenience, returns all fields for the TempFamilyGuardian.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('TempFamilyGuardian') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of TempFamilyGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getTempFamilyGuardian <- function(TempFamilyGuardianID, CreatedTime = F, GuardianNameID = F, GuardianNameLFM = F, IsFamilyAccessUser = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "TempFamilyGuardianID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "TempFamilyGuardian", objectId = TempFamilyGuardianID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a TempFamilyGuardian
#'
#' This function deletes a TempFamilyGuardian
#' @param TempFamilyGuardianID The ID of the TempFamilyGuardian to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The TempFamilyGuardianID of the deleted TempFamilyGuardian.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteTempFamilyGuardian <- function(TempFamilyGuardianID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "TempFamilyGuardian", objectId = TempFamilyGuardianID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a TempFamilyGuardian
#'
#' This function creates a TempFamilyGuardian
#' @param fieldNames The field values to give the created TempFamilyGuardian. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created TempFamilyGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createTempFamilyGuardian <- function(GuardianNameID = NULL, GuardianNameLFM = NULL, IsFamilyAccessUser = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "TempFamilyGuardian", body = list(DataObject = body), searchFields = append("TempFamilyGuardianID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a TempFamilyGuardian
#'
#' This function modifies a TempFamilyGuardian
#' @param fieldNames The field values to give the modified TempFamilyGuardian. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified TempFamilyGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyTempFamilyGuardian <- function(TempFamilyGuardianID, GuardianNameID = NULL, GuardianNameLFM = NULL, IsFamilyAccessUser = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "TempFamilyGuardian", objectId = TempFamilyGuardianID, body = list(DataObject = body), searchFields = append("TempFamilyGuardianID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List StudentGuardians
#'
#' This function returns a dataframe or json object of StudentGuardians
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentGuardians. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentGuardians.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentGuardian') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of StudentGuardians
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listStudentGuardians <- function(searchConditionsList = NULL, AllowFamilyAccess = F, AllowStudentPickup = F, CreatedTime = F, FeeOnlinePaymentOverrideType = F, FoodOnlinePaymentOverrideType = F, GuardianCategory = F, GuardianNameIDAndFamilyID = F, HasActiveRestrictedAccess = F, HasUnrestrictedAccess = F, IsCustodialGuardian = F, IsEmergencyContact = F, ModifiedTime = F, NameIDGuardian = F, NeedsSecurityGroupAudit = F, OverrideFeeOnlinePaymentAccess = F, OverrideFoodOnlinePaymentAccess = F, Rank = F, RelationshipID = F, StudentGuardianID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "StudentGuardian", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a StudentGuardian
#'
#' This function returns a dataframe or json object of a StudentGuardian
#' @param StudentGuardianID The ID of the StudentGuardian to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentGuardian. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentGuardian.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentGuardian') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of StudentGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getStudentGuardian <- function(StudentGuardianID, AllowFamilyAccess = F, AllowStudentPickup = F, CreatedTime = F, FeeOnlinePaymentOverrideType = F, FoodOnlinePaymentOverrideType = F, GuardianCategory = F, GuardianNameIDAndFamilyID = F, HasActiveRestrictedAccess = F, HasUnrestrictedAccess = F, IsCustodialGuardian = F, IsEmergencyContact = F, ModifiedTime = F, NameIDGuardian = F, NeedsSecurityGroupAudit = F, OverrideFeeOnlinePaymentAccess = F, OverrideFoodOnlinePaymentAccess = F, Rank = F, RelationshipID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "StudentGuardianID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "StudentGuardian", objectId = StudentGuardianID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a StudentGuardian
#'
#' This function deletes a StudentGuardian
#' @param StudentGuardianID The ID of the StudentGuardian to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The StudentGuardianID of the deleted StudentGuardian.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteStudentGuardian <- function(StudentGuardianID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "StudentGuardian", objectId = StudentGuardianID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a StudentGuardian
#'
#' This function creates a StudentGuardian
#' @param fieldNames The field values to give the created StudentGuardian. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created StudentGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createStudentGuardian <- function(AllowFamilyAccess = NULL, AllowStudentPickup = NULL, FeeOnlinePaymentOverrideType = NULL, FoodOnlinePaymentOverrideType = NULL, IsCustodialGuardian = NULL, NameIDGuardian = NULL, OverrideFeeOnlinePaymentAccess = NULL, OverrideFoodOnlinePaymentAccess = NULL, RelationshipID = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "StudentGuardian", body = list(DataObject = body), searchFields = append("StudentGuardianID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a StudentGuardian
#'
#' This function modifies a StudentGuardian
#' @param fieldNames The field values to give the modified StudentGuardian. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified StudentGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyStudentGuardian <- function(StudentGuardianID, AllowFamilyAccess = NULL, AllowStudentPickup = NULL, FeeOnlinePaymentOverrideType = NULL, FoodOnlinePaymentOverrideType = NULL, IsCustodialGuardian = NULL, NameIDGuardian = NULL, OverrideFeeOnlinePaymentAccess = NULL, OverrideFoodOnlinePaymentAccess = NULL, RelationshipID = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "StudentGuardian", objectId = StudentGuardianID, body = list(DataObject = body), searchFields = append("StudentGuardianID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List StudentFamilies
#'
#' This function returns a dataframe or json object of StudentFamilies
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentFamilies. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentFamilies.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentFamily') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of StudentFamilies
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listStudentFamilies <- function(searchConditionsList = NULL, AttachmentCount = F, CreatedTime = F, FamilyID = F, IsEmergencyContact = F, IsPrimaryEmergencyContact = F, ModifiedTime = F, Rank = F, ReceivesForms = F, StudentFamilyID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "StudentFamily", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a StudentFamily
#'
#' This function returns a dataframe or json object of a StudentFamily
#' @param StudentFamilyID The ID of the StudentFamily to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentFamily. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentFamily.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentFamily') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of StudentFamily
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getStudentFamily <- function(StudentFamilyID, AttachmentCount = F, CreatedTime = F, FamilyID = F, IsEmergencyContact = F, IsPrimaryEmergencyContact = F, ModifiedTime = F, Rank = F, ReceivesForms = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "StudentFamilyID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "StudentFamily", objectId = StudentFamilyID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a StudentFamily
#'
#' This function deletes a StudentFamily
#' @param StudentFamilyID The ID of the StudentFamily to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The StudentFamilyID of the deleted StudentFamily.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteStudentFamily <- function(StudentFamilyID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "StudentFamily", objectId = StudentFamilyID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a StudentFamily
#'
#' This function creates a StudentFamily
#' @param fieldNames The field values to give the created StudentFamily. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created StudentFamily
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createStudentFamily <- function(FamilyID = NULL, Rank = NULL, ReceivesForms = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "StudentFamily", body = list(DataObject = body), searchFields = append("StudentFamilyID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a StudentFamily
#'
#' This function modifies a StudentFamily
#' @param fieldNames The field values to give the modified StudentFamily. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified StudentFamily
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyStudentFamily <- function(StudentFamilyID, FamilyID = NULL, Rank = NULL, ReceivesForms = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "StudentFamily", objectId = StudentFamilyID, body = list(DataObject = body), searchFields = append("StudentFamilyID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List FamilyGuardians
#'
#' This function returns a dataframe or json object of FamilyGuardians
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyGuardians. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyGuardians.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyGuardian') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of FamilyGuardians
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilyGuardians <- function(searchConditionsList = NULL, CreatedTime = F, FamilyGuardianID = F, FamilyID = F, HasActiveStudentGuardianRestrictedAccess = F, ModifiedTime = F, NameID = F, Rank = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "FamilyGuardian", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a FamilyGuardian
#'
#' This function returns a dataframe or json object of a FamilyGuardian
#' @param FamilyGuardianID The ID of the FamilyGuardian to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyGuardian. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyGuardian.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyGuardian') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of FamilyGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamilyGuardian <- function(FamilyGuardianID, CreatedTime = F, FamilyID = F, HasActiveStudentGuardianRestrictedAccess = F, ModifiedTime = F, NameID = F, Rank = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyGuardianID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "FamilyGuardian", objectId = FamilyGuardianID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a FamilyGuardian
#'
#' This function deletes a FamilyGuardian
#' @param FamilyGuardianID The ID of the FamilyGuardian to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyGuardianID of the deleted FamilyGuardian.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamilyGuardian <- function(FamilyGuardianID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "FamilyGuardian", objectId = FamilyGuardianID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a FamilyGuardian
#'
#' This function creates a FamilyGuardian
#' @param fieldNames The field values to give the created FamilyGuardian. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created FamilyGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamilyGuardian <- function(FamilyID = NULL, NameID = NULL, Rank = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "FamilyGuardian", body = list(DataObject = body), searchFields = append("FamilyGuardianID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a FamilyGuardian
#'
#' This function modifies a FamilyGuardian
#' @param fieldNames The field values to give the modified FamilyGuardian. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified FamilyGuardian
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamilyGuardian <- function(FamilyGuardianID, FamilyID = NULL, NameID = NULL, Rank = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "FamilyGuardian", objectId = FamilyGuardianID, body = list(DataObject = body), searchFields = append("FamilyGuardianID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List Families
#'
#' This function returns a dataframe or json object of Families
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given Families. Defaults to FALSE for all return fields which, for convenience, returns all fields for the Families.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('Family') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of Families
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilies <- function(searchConditionsList = NULL, AttachmentCount = F, CreatedTime = F, FamilyID = F, HasStudentInSpecificDistrict = F, LanguageIDHome = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "Family", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a Family
#'
#' This function returns a dataframe or json object of a Family
#' @param FamilyID The ID of the Family to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given Family. Defaults to FALSE for all return fields which, for convenience, returns all fields for the Family.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('Family') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of Family
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamily <- function(FamilyID, AttachmentCount = F, CreatedTime = F, HasStudentInSpecificDistrict = F, LanguageIDHome = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "Family", objectId = FamilyID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a Family
#'
#' This function deletes a Family
#' @param FamilyID The ID of the Family to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyID of the deleted Family.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamily <- function(FamilyID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "Family", objectId = FamilyID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a Family
#'
#' This function creates a Family
#' @param fieldNames The field values to give the created Family. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created Family
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamily <- function(LanguageIDHome = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "Family", body = list(DataObject = body), searchFields = append("FamilyID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a Family
#'
#' This function modifies a Family
#' @param fieldNames The field values to give the modified Family. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified Family
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamily <- function(FamilyID, LanguageIDHome = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "Family", objectId = FamilyID, body = list(DataObject = body), searchFields = append("FamilyID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List StudentGuardianRestrictedAccesses
#'
#' This function returns a dataframe or json object of StudentGuardianRestrictedAccesses
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentGuardianRestrictedAccesses. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentGuardianRestrictedAccesses.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentGuardianRestrictedAccess') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of StudentGuardianRestrictedAccesses
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listStudentGuardianRestrictedAccesses <- function(searchConditionsList = NULL, AttachmentCount = F, CreatedTime = F, EndDate = F, ModifiedTime = F, Reason = F, StartDate = F, StudentGuardianID = F, StudentGuardianRestrictedAccessID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "StudentGuardianRestrictedAccess", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a StudentGuardianRestrictedAccess
#'
#' This function returns a dataframe or json object of a StudentGuardianRestrictedAccess
#' @param StudentGuardianRestrictedAccessID The ID of the StudentGuardianRestrictedAccess to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentGuardianRestrictedAccess. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentGuardianRestrictedAccess.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentGuardianRestrictedAccess') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of StudentGuardianRestrictedAccess
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getStudentGuardianRestrictedAccess <- function(StudentGuardianRestrictedAccessID, AttachmentCount = F, CreatedTime = F, EndDate = F, ModifiedTime = F, Reason = F, StartDate = F, StudentGuardianID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "StudentGuardianRestrictedAccessID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "StudentGuardianRestrictedAccess", objectId = StudentGuardianRestrictedAccessID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a StudentGuardianRestrictedAccess
#'
#' This function deletes a StudentGuardianRestrictedAccess
#' @param StudentGuardianRestrictedAccessID The ID of the StudentGuardianRestrictedAccess to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The StudentGuardianRestrictedAccessID of the deleted StudentGuardianRestrictedAccess.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteStudentGuardianRestrictedAccess <- function(StudentGuardianRestrictedAccessID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "StudentGuardianRestrictedAccess", objectId = StudentGuardianRestrictedAccessID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a StudentGuardianRestrictedAccess
#'
#' This function creates a StudentGuardianRestrictedAccess
#' @param fieldNames The field values to give the created StudentGuardianRestrictedAccess. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created StudentGuardianRestrictedAccess
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createStudentGuardianRestrictedAccess <- function(EndDate = NULL, Reason = NULL, StartDate = NULL, StudentGuardianID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "StudentGuardianRestrictedAccess", body = list(DataObject = body), searchFields = append("StudentGuardianRestrictedAccessID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a StudentGuardianRestrictedAccess
#'
#' This function modifies a StudentGuardianRestrictedAccess
#' @param fieldNames The field values to give the modified StudentGuardianRestrictedAccess. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified StudentGuardianRestrictedAccess
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyStudentGuardianRestrictedAccess <- function(StudentGuardianRestrictedAccessID, EndDate = NULL, Reason = NULL, StartDate = NULL, StudentGuardianID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "StudentGuardianRestrictedAccess", objectId = StudentGuardianRestrictedAccessID, body = list(DataObject = body), searchFields = append("StudentGuardianRestrictedAccessID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List FamilyConfigDistricts
#'
#' This function returns a dataframe or json object of FamilyConfigDistricts
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyConfigDistricts. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyConfigDistricts.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyConfigDistrict') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of FamilyConfigDistricts
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilyConfigDistricts <- function(searchConditionsList = NULL, ConfigDistrictID = F, CreatedTime = F, DisplayDefaultContact = F, DisplayModuleContact = F, DistrictID = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ConfigDistrict", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a FamilyConfigDistrict
#'
#' This function returns a dataframe or json object of a FamilyConfigDistrict
#' @param FamilyConfigDistrictID The ID of the FamilyConfigDistrict to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyConfigDistrict. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyConfigDistrict.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyConfigDistrict') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of FamilyConfigDistrict
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamilyConfigDistrict <- function(FamilyConfigDistrictID, ConfigDistrictID = F, CreatedTime = F, DisplayDefaultContact = F, DisplayModuleContact = F, DistrictID = F, ModifiedTime = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyConfigDistrictID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ConfigDistrict", objectId = FamilyConfigDistrictID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a FamilyConfigDistrict
#'
#' This function deletes a FamilyConfigDistrict
#' @param FamilyConfigDistrictID The ID of the FamilyConfigDistrict to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyConfigDistrictID of the deleted FamilyConfigDistrict.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamilyConfigDistrict <- function(FamilyConfigDistrictID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ConfigDistrict", objectId = FamilyConfigDistrictID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a FamilyConfigDistrict
#'
#' This function creates a FamilyConfigDistrict
#' @param fieldNames The field values to give the created FamilyConfigDistrict. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created FamilyConfigDistrict
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamilyConfigDistrict <- function(DistrictID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ConfigDistrict", body = list(DataObject = body), searchFields = append("ConfigDistrictID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a FamilyConfigDistrict
#'
#' This function modifies a FamilyConfigDistrict
#' @param fieldNames The field values to give the modified FamilyConfigDistrict. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified FamilyConfigDistrict
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamilyConfigDistrict <- function(ConfigDistrictID, DistrictID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ConfigDistrict", objectId = ConfigDistrictID, body = list(DataObject = body), searchFields = append("ConfigDistrictID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List ConfigDistrictContacts
#'
#' This function returns a dataframe or json object of ConfigDistrictContacts
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ConfigDistrictContacts. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ConfigDistrictContacts.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ConfigDistrictContact') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of ConfigDistrictContacts
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listConfigDistrictContacts <- function(searchConditionsList = NULL, CanDisplayEmail = F, CanDisplayPhone = F, ConfigDistrictContactID = F, ConfigDistrictID = F, CreatedTime = F, DisplayEmail = F, DisplayPhone = F, EmailTypeID = F, ModifiedTime = F, Module = F, ModuleDisplay = F, NameID = F, PhoneTypeID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ConfigDistrictContact", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a ConfigDistrictContact
#'
#' This function returns a dataframe or json object of a ConfigDistrictContact
#' @param ConfigDistrictContactID The ID of the ConfigDistrictContact to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ConfigDistrictContact. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ConfigDistrictContact.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ConfigDistrictContact') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of ConfigDistrictContact
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getConfigDistrictContact <- function(ConfigDistrictContactID, CanDisplayEmail = F, CanDisplayPhone = F, ConfigDistrictID = F, CreatedTime = F, DisplayEmail = F, DisplayPhone = F, EmailTypeID = F, ModifiedTime = F, Module = F, ModuleDisplay = F, NameID = F, PhoneTypeID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "ConfigDistrictContactID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ConfigDistrictContact", objectId = ConfigDistrictContactID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a ConfigDistrictContact
#'
#' This function deletes a ConfigDistrictContact
#' @param ConfigDistrictContactID The ID of the ConfigDistrictContact to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The ConfigDistrictContactID of the deleted ConfigDistrictContact.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteConfigDistrictContact <- function(ConfigDistrictContactID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ConfigDistrictContact", objectId = ConfigDistrictContactID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a ConfigDistrictContact
#'
#' This function creates a ConfigDistrictContact
#' @param fieldNames The field values to give the created ConfigDistrictContact. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created ConfigDistrictContact
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createConfigDistrictContact <- function(ConfigDistrictID = NULL, DisplayEmail = NULL, DisplayPhone = NULL, EmailTypeID = NULL, Module = NULL, NameID = NULL, PhoneTypeID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ConfigDistrictContact", body = list(DataObject = body), searchFields = append("ConfigDistrictContactID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a ConfigDistrictContact
#'
#' This function modifies a ConfigDistrictContact
#' @param fieldNames The field values to give the modified ConfigDistrictContact. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified ConfigDistrictContact
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyConfigDistrictContact <- function(ConfigDistrictContactID, ConfigDistrictID = NULL, DisplayEmail = NULL, DisplayPhone = NULL, EmailTypeID = NULL, Module = NULL, NameID = NULL, PhoneTypeID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ConfigDistrictContact", objectId = ConfigDistrictContactID, body = list(DataObject = body), searchFields = append("ConfigDistrictContactID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List ConfigEntityGroupYearStaffDirectories
#'
#' This function returns a dataframe or json object of ConfigEntityGroupYearStaffDirectories
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ConfigEntityGroupYearStaffDirectories. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ConfigEntityGroupYearStaffDirectories.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ConfigEntityGroupYearStaffDirectory') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of ConfigEntityGroupYearStaffDirectories
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listConfigEntityGroupYearStaffDirectories <- function(searchConditionsList = NULL, ConfigEntityGroupYearID = F, ConfigEntityGroupYearStaffDirectoryID = F, CreatedTime = F, DisplayEmail = F, DisplayPhone = F, EmailTypeID = F, ModifiedTime = F, PhoneTypeID = F, StaffTypeID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "ConfigEntityGroupYearStaffDirectory", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a ConfigEntityGroupYearStaffDirectory
#'
#' This function returns a dataframe or json object of a ConfigEntityGroupYearStaffDirectory
#' @param ConfigEntityGroupYearStaffDirectoryID The ID of the ConfigEntityGroupYearStaffDirectory to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given ConfigEntityGroupYearStaffDirectory. Defaults to FALSE for all return fields which, for convenience, returns all fields for the ConfigEntityGroupYearStaffDirectory.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('ConfigEntityGroupYearStaffDirectory') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of ConfigEntityGroupYearStaffDirectory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getConfigEntityGroupYearStaffDirectory <- function(ConfigEntityGroupYearStaffDirectoryID, ConfigEntityGroupYearID = F, CreatedTime = F, DisplayEmail = F, DisplayPhone = F, EmailTypeID = F, ModifiedTime = F, PhoneTypeID = F, StaffTypeID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "ConfigEntityGroupYearStaffDirectoryID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "ConfigEntityGroupYearStaffDirectory", objectId = ConfigEntityGroupYearStaffDirectoryID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a ConfigEntityGroupYearStaffDirectory
#'
#' This function deletes a ConfigEntityGroupYearStaffDirectory
#' @param ConfigEntityGroupYearStaffDirectoryID The ID of the ConfigEntityGroupYearStaffDirectory to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The ConfigEntityGroupYearStaffDirectoryID of the deleted ConfigEntityGroupYearStaffDirectory.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteConfigEntityGroupYearStaffDirectory <- function(ConfigEntityGroupYearStaffDirectoryID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "ConfigEntityGroupYearStaffDirectory", objectId = ConfigEntityGroupYearStaffDirectoryID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a ConfigEntityGroupYearStaffDirectory
#'
#' This function creates a ConfigEntityGroupYearStaffDirectory
#' @param fieldNames The field values to give the created ConfigEntityGroupYearStaffDirectory. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created ConfigEntityGroupYearStaffDirectory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createConfigEntityGroupYearStaffDirectory <- function(ConfigEntityGroupYearID = NULL, DisplayEmail = NULL, DisplayPhone = NULL, EmailTypeID = NULL, PhoneTypeID = NULL, StaffTypeID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "ConfigEntityGroupYearStaffDirectory", body = list(DataObject = body), searchFields = append("ConfigEntityGroupYearStaffDirectoryID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a ConfigEntityGroupYearStaffDirectory
#'
#' This function modifies a ConfigEntityGroupYearStaffDirectory
#' @param fieldNames The field values to give the modified ConfigEntityGroupYearStaffDirectory. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified ConfigEntityGroupYearStaffDirectory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyConfigEntityGroupYearStaffDirectory <- function(ConfigEntityGroupYearStaffDirectoryID, ConfigEntityGroupYearID = NULL, DisplayEmail = NULL, DisplayPhone = NULL, EmailTypeID = NULL, PhoneTypeID = NULL, StaffTypeID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "ConfigEntityGroupYearStaffDirectory", objectId = ConfigEntityGroupYearStaffDirectoryID, body = list(DataObject = body), searchFields = append("ConfigEntityGroupYearStaffDirectoryID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List EmployerInformations
#'
#' This function returns a dataframe or json object of EmployerInformations
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given EmployerInformations. Defaults to FALSE for all return fields which, for convenience, returns all fields for the EmployerInformations.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('EmployerInformation') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of EmployerInformations
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listEmployerInformations <- function(searchConditionsList = NULL, EmployerInformationID = F, FamilyGuardianID = F, Occupation = F, PlaceofEmployment = F, WorkAddress = F, WorkPhoneNumber = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "EmployerInformation", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get an EmployerInformation
#'
#' This function returns a dataframe or json object of an EmployerInformation
#' @param EmployerInformationID The ID of the EmployerInformation to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given EmployerInformation. Defaults to FALSE for all return fields which, for convenience, returns all fields for the EmployerInformation.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('EmployerInformation') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of EmployerInformation
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getEmployerInformation <- function(EmployerInformationID, FamilyGuardianID = F, Occupation = F, PlaceofEmployment = F, WorkAddress = F, WorkPhoneNumber = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "EmployerInformationID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "EmployerInformation", objectId = EmployerInformationID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete an EmployerInformation
#'
#' This function deletes an EmployerInformation
#' @param EmployerInformationID The ID of the EmployerInformation to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The EmployerInformationID of the deleted EmployerInformation.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteEmployerInformation <- function(EmployerInformationID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "EmployerInformation", objectId = EmployerInformationID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create an EmployerInformation
#'
#' This function creates an EmployerInformation
#' @param fieldNames The field values to give the created EmployerInformation. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created EmployerInformation
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createEmployerInformation <- function(FamilyGuardianID = NULL, Occupation = NULL, PlaceofEmployment = NULL, WorkAddress = NULL, WorkPhoneNumber = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "EmployerInformation", body = list(DataObject = body), searchFields = append("EmployerInformationID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify an EmployerInformation
#'
#' This function modifies an EmployerInformation
#' @param fieldNames The field values to give the modified EmployerInformation. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified EmployerInformation
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyEmployerInformation <- function(EmployerInformationID, FamilyGuardianID = NULL, Occupation = NULL, PlaceofEmployment = NULL, WorkAddress = NULL, WorkPhoneNumber = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "EmployerInformation", objectId = EmployerInformationID, body = list(DataObject = body), searchFields = append("EmployerInformationID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List FamilyStudentAccounts
#'
#' This function returns a dataframe or json object of FamilyStudentAccounts
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyStudentAccounts. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyStudentAccounts.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyStudentAccounts') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of FamilyStudentAccounts
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilyStudentAccounts <- function(searchConditionsList = NULL, FamilyID = F, FamilyStudentAccountsID = F, PlaceOfWorship = F, ReligionID = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "FamilyStudentAccounts", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a FamilyStudentAccounts
#'
#' This function returns a dataframe or json object of a FamilyStudentAccounts
#' @param FamilyStudentAccountsID The ID of the FamilyStudentAccounts to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyStudentAccounts. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyStudentAccounts.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyStudentAccounts') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of FamilyStudentAccounts
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamilyStudentAccounts <- function(FamilyStudentAccountsID, FamilyID = F, PlaceOfWorship = F, ReligionID = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyStudentAccountsID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "FamilyStudentAccounts", objectId = FamilyStudentAccountsID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a FamilyStudentAccounts
#'
#' This function deletes a FamilyStudentAccounts
#' @param FamilyStudentAccountsID The ID of the FamilyStudentAccounts to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyStudentAccountsID of the deleted FamilyStudentAccounts.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamilyStudentAccounts <- function(FamilyStudentAccountsID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "FamilyStudentAccounts", objectId = FamilyStudentAccountsID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a FamilyStudentAccounts
#'
#' This function creates a FamilyStudentAccounts
#' @param fieldNames The field values to give the created FamilyStudentAccounts. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created FamilyStudentAccounts
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamilyStudentAccounts <- function(FamilyID = NULL, PlaceOfWorship = NULL, ReligionID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "FamilyStudentAccounts", body = list(DataObject = body), searchFields = append("FamilyStudentAccountsID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a FamilyStudentAccounts
#'
#' This function modifies a FamilyStudentAccounts
#' @param fieldNames The field values to give the modified FamilyStudentAccounts. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified FamilyStudentAccounts
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamilyStudentAccounts <- function(FamilyStudentAccountsID, FamilyID = NULL, PlaceOfWorship = NULL, ReligionID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "FamilyStudentAccounts", objectId = FamilyStudentAccountsID, body = list(DataObject = body), searchFields = append("FamilyStudentAccountsID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List FamilyAccessUsageHistories
#'
#' This function returns a dataframe or json object of FamilyAccessUsageHistories
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyAccessUsageHistories. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyAccessUsageHistories.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyAccessUsageHistory') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of FamilyAccessUsageHistories
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listFamilyAccessUsageHistories <- function(searchConditionsList = NULL, CreatedTime = F, DisplayScreen = F, EntityID = F, FamilyAccessUsageHistoryID = F, FriendlyNameScreen = F, ModifiedTime = F, SecurityLocationID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "FamilyAccessUsageHistory", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a FamilyAccessUsageHistory
#'
#' This function returns a dataframe or json object of a FamilyAccessUsageHistory
#' @param FamilyAccessUsageHistoryID The ID of the FamilyAccessUsageHistory to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given FamilyAccessUsageHistory. Defaults to FALSE for all return fields which, for convenience, returns all fields for the FamilyAccessUsageHistory.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('FamilyAccessUsageHistory') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of FamilyAccessUsageHistory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getFamilyAccessUsageHistory <- function(FamilyAccessUsageHistoryID, CreatedTime = F, DisplayScreen = F, EntityID = F, FriendlyNameScreen = F, ModifiedTime = F, SecurityLocationID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "FamilyAccessUsageHistoryID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "FamilyAccessUsageHistory", objectId = FamilyAccessUsageHistoryID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a FamilyAccessUsageHistory
#'
#' This function deletes a FamilyAccessUsageHistory
#' @param FamilyAccessUsageHistoryID The ID of the FamilyAccessUsageHistory to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The FamilyAccessUsageHistoryID of the deleted FamilyAccessUsageHistory.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteFamilyAccessUsageHistory <- function(FamilyAccessUsageHistoryID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "FamilyAccessUsageHistory", objectId = FamilyAccessUsageHistoryID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a FamilyAccessUsageHistory
#'
#' This function creates a FamilyAccessUsageHistory
#' @param fieldNames The field values to give the created FamilyAccessUsageHistory. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created FamilyAccessUsageHistory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createFamilyAccessUsageHistory <- function(EntityID = NULL, FriendlyNameScreen = NULL, SecurityLocationID = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "FamilyAccessUsageHistory", body = list(DataObject = body), searchFields = append("FamilyAccessUsageHistoryID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a FamilyAccessUsageHistory
#'
#' This function modifies a FamilyAccessUsageHistory
#' @param fieldNames The field values to give the modified FamilyAccessUsageHistory. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified FamilyAccessUsageHistory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyFamilyAccessUsageHistory <- function(FamilyAccessUsageHistoryID, EntityID = NULL, FriendlyNameScreen = NULL, SecurityLocationID = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "FamilyAccessUsageHistory", objectId = FamilyAccessUsageHistoryID, body = list(DataObject = body), searchFields = append("FamilyAccessUsageHistoryID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List StudentAccessUsageHistories
#'
#' This function returns a dataframe or json object of StudentAccessUsageHistories
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentAccessUsageHistories. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentAccessUsageHistories.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentAccessUsageHistory') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of StudentAccessUsageHistories
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listStudentAccessUsageHistories <- function(searchConditionsList = NULL, CreatedTime = F, DisplayScreen = F, EntityID = F, FriendlyNameScreen = F, ModifiedTime = F, SecurityLocationID = F, StudentAccessUsageHistoryID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "StudentAccessUsageHistory", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a StudentAccessUsageHistory
#'
#' This function returns a dataframe or json object of a StudentAccessUsageHistory
#' @param StudentAccessUsageHistoryID The ID of the StudentAccessUsageHistory to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentAccessUsageHistory. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentAccessUsageHistory.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentAccessUsageHistory') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of StudentAccessUsageHistory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getStudentAccessUsageHistory <- function(StudentAccessUsageHistoryID, CreatedTime = F, DisplayScreen = F, EntityID = F, FriendlyNameScreen = F, ModifiedTime = F, SecurityLocationID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "StudentAccessUsageHistoryID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "StudentAccessUsageHistory", objectId = StudentAccessUsageHistoryID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a StudentAccessUsageHistory
#'
#' This function deletes a StudentAccessUsageHistory
#' @param StudentAccessUsageHistoryID The ID of the StudentAccessUsageHistory to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The StudentAccessUsageHistoryID of the deleted StudentAccessUsageHistory.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteStudentAccessUsageHistory <- function(StudentAccessUsageHistoryID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "StudentAccessUsageHistory", objectId = StudentAccessUsageHistoryID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a StudentAccessUsageHistory
#'
#' This function creates a StudentAccessUsageHistory
#' @param fieldNames The field values to give the created StudentAccessUsageHistory. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created StudentAccessUsageHistory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createStudentAccessUsageHistory <- function(EntityID = NULL, FriendlyNameScreen = NULL, SecurityLocationID = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "StudentAccessUsageHistory", body = list(DataObject = body), searchFields = append("StudentAccessUsageHistoryID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a StudentAccessUsageHistory
#'
#' This function modifies a StudentAccessUsageHistory
#' @param fieldNames The field values to give the modified StudentAccessUsageHistory. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified StudentAccessUsageHistory
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyStudentAccessUsageHistory <- function(StudentAccessUsageHistoryID, EntityID = NULL, FriendlyNameScreen = NULL, SecurityLocationID = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "StudentAccessUsageHistory", objectId = StudentAccessUsageHistoryID, body = list(DataObject = body), searchFields = append("StudentAccessUsageHistoryID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' List StudentCalendarNotes
#'
#' This function returns a dataframe or json object of StudentCalendarNotes
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentCalendarNotes. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentCalendarNotes.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentCalendarNote') to get more field paths.
#' @param searchConditionsList A list of search conditions to filter results which are joined by the searchConditionsGroupType. Of the form {FieldName} {ConditionType} {SearchCondition}. For example, c('StudentID LessEqual 500', 'LastName Like Ander\%'). Run \code{\link{listSearchConditionTypes}} for a list of ConditionTypes. Defaults to NULL (unfiltered).
#' @param searchConditionsGroupType The conjunction which joins multiple searchConditions in the searchConditionsList. Either 'Or' or 'And'. Defaults to 'And'.
#' @param searchSortFieldNamesList The list of fields sort results by. Defaults to NULL (unsorted).
#' @param searchSortFieldNamesDescendingList A list of T/F values corresponding to whether to sort each field in searchSortFieldNamesList in descending order. Defaults to F for each FieldName in searchSortFieldNamesList.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param page Results are paginated. The page of results to return. Default is 1.
#' @param pageSize Results are paginated. The number of records per page to return. Default is 100,000 (essentially all records for most objects).
#' @param flatten Whether to flatten results into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A list of StudentCalendarNotes
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
listStudentCalendarNotes <- function(searchConditionsList = NULL, CreatedTime = F, Date = F, Description = F, ModifiedTime = F, Note = F, PriorityType = F, StudentCalendarNoteID = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, searchConditionsGroupType = "And", searchSortFieldNamesList = NULL, searchSortFieldNamesDescendingList = NULL, entityId = 1, query = NULL, page = 1, pageSize = 100000, flatten = T, returnResponse = F){
params <- as.list(environment())
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
listSkyObjects(module = "Family", objectName = "StudentCalendarNote", searchFields = searchFields %>% append(fieldPaths), page = page, pageSize = pageSize, SearchConditionsList = searchConditionsList, SearchConditionsGroupType = searchConditionsGroupType, SearchSortFieldNamesList = searchSortFieldNamesList, SearchSortFieldNamesDescendingList = searchSortFieldNamesDescendingList, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Get a StudentCalendarNote
#'
#' This function returns a dataframe or json object of a StudentCalendarNote
#' @param StudentCalendarNoteID The ID of the StudentCalendarNote to return.
#' @param fieldNames A TRUE or FALSE value determining whether or not to return the field for the given StudentCalendarNote. Defaults to FALSE for all return fields which, for convenience, returns all fields for the StudentCalendarNote.
#' @param fieldPaths Fields from other objects with 'Many to One' or 'One to One' relationships to the given object listed as text. Run \code{\link{getSchemaForObjects}}('StudentCalendarNote') to get more field paths.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A dataframe or of StudentCalendarNote
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
getStudentCalendarNote <- function(StudentCalendarNoteID, CreatedTime = F, Date = F, Description = F, ModifiedTime = F, Note = F, PriorityType = F, StudentID = F, UserIDCreatedBy = F, UserIDModifiedBy = F, fieldPaths = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment()) %>% purrr::keep(names(.) != "StudentCalendarNoteID")
searchFields <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper())
ifelse(!any(searchFields %>% unlist()), searchFields <- searchFields %>% names(), searchFields <- searchFields %>% purrr::keep(~.x) %>% names())
getSkyObject(module = "Family", objectName = "StudentCalendarNote", objectId = StudentCalendarNoteID, searchFields = searchFields, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Delete a StudentCalendarNote
#'
#' This function deletes a StudentCalendarNote
#' @param StudentCalendarNoteID The ID of the StudentCalendarNote to delete
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The StudentCalendarNoteID of the deleted StudentCalendarNote.
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
deleteStudentCalendarNote <- function(StudentCalendarNoteID, ignoreWarnings = F, entityId = 1, query = NULL, flatten = T, returnResponse = F){
deleteSkyObject(module = "Family", objectName = "StudentCalendarNote", objectId = StudentCalendarNoteID, ignoreWarnings = ignoreWarnings, entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Create a StudentCalendarNote
#'
#' This function creates a StudentCalendarNote
#' @param fieldNames The field values to give the created StudentCalendarNote. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return A newly created StudentCalendarNote
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
createStudentCalendarNote <- function(Date = NULL, Description = NULL, Note = NULL, PriorityType = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
createSkyObject(module = "Family", objectName = "StudentCalendarNote", body = list(DataObject = body), searchFields = append("StudentCalendarNoteID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
#' Modify a StudentCalendarNote
#'
#' This function modifies a StudentCalendarNote
#' @param fieldNames The field values to give the modified StudentCalendarNote. Each defaults to NULL.
#' @param entityId The id of the entity (school). Run \code{\link{listEntities}} for a list of entities. Defaults to 1 (district).
#' @param query Queries to be added to the request. Ex. list(SchoolYearID = 1). Defaults to NULL.
#' @param flatten Whether to flatten result into a dataframe or return the json object. Default is TRUE (flatten to dataframe).
#' @param returnResponse Whether to return the server response instead of the results. Useful for debugging. Default is FALSE.
#' @concept Family
#' @return The modified StudentCalendarNote
#' \href{https://help.skyward.com/}{Skyward's Knowledge Hub}
#' @export
modifyStudentCalendarNote <- function(StudentCalendarNoteID, Date = NULL, Description = NULL, Note = NULL, PriorityType = NULL, StudentID = NULL, entityId = 1, query = NULL, flatten = T, returnResponse = F){
params <- as.list(environment())
body <- params %>% purrr::keep(names(params) %>% stringr::str_sub(1,1) == names(params) %>% stringr::str_sub(1,1) %>% stringr::str_to_upper()) %>% purrr::compact()
modifySkyObject(module = "Family", objectName = "StudentCalendarNote", objectId = StudentCalendarNoteID, body = list(DataObject = body), searchFields = append("StudentCalendarNoteID", body %>% names()), entityId = entityId, query = query, flatten = flatten, returnResponse = returnResponse)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.