# VerityReputation.PersonApi

All URIs are relative to *http://springserver.cfapps.io/verity/core*

Method | HTTP request | Description
------------- | ------------- | -------------
[**createPerson**](PersonApi.md#createPerson) | **POST** /person | create person
[**gETPerson**](PersonApi.md#gETPerson) | **GET** /person | get Person by qeury parameters
[**gETPersonUuidReputationCommunityidValuetypeidReputationtype**](PersonApi.md#gETPersonUuidReputationCommunityidValuetypeidReputationtype) | **GET** /person/{uuid}/reputation/{communityid}/{valuetypeid}/{reputationtype} | get person reputation
[**getPerson**](PersonApi.md#getPerson) | **GET** /person/{uuid} | get Person
[**getPersonContent**](PersonApi.md#getPersonContent) | **GET** /person/{uuid}/content | get Person Content
[**updatePerson**](PersonApi.md#updatePerson) | **PUT** /person | update person


<a name="createPerson"></a>
# **createPerson**
> Person createPerson(opts)

create person

### Example
```javascript
var VerityReputation = require('verity_reputation');

var apiInstance = new VerityReputation.PersonApi();

var opts = { 
  'body': new VerityReputation.Person() // Person | 
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.createPerson(opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | [**Person**](Person.md)|  | [optional] 

### Return type

[**Person**](Person.md)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

<a name="gETPerson"></a>
# **gETPerson**
> [Person] gETPerson(opts)

get Person by qeury parameters

### Example
```javascript
var VerityReputation = require('verity_reputation');

var apiInstance = new VerityReputation.PersonApi();

var opts = { 
  'firstname': "firstname_example", // String | 
  'lastname': "lastname_example", // String | 
  'nickname': "nickname_example" // String | 
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.gETPerson(opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **firstname** | **String**|  | [optional] 
 **lastname** | **String**|  | [optional] 
 **nickname** | **String**|  | [optional] 

### Return type

[**[Person]**](Person.md)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="gETPersonUuidReputationCommunityidValuetypeidReputationtype"></a>
# **gETPersonUuidReputationCommunityidValuetypeidReputationtype**
> &#39;Number&#39; gETPersonUuidReputationCommunityidValuetypeidReputationtype(uuid, communityid, valuetypeid, reputationtype)

get person reputation

Get the reputation as calculated by the algorithm requested in the reputationtype parameter.

### Example
```javascript
var VerityReputation = require('verity_reputation');

var apiInstance = new VerityReputation.PersonApi();

var uuid = "uuid_example"; // String | 

var communityid = "communityid_example"; // String | 

var valuetypeid = "valuetypeid_example"; // String | 

var reputationtype = "reputationtype_example"; // String | 


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.gETPersonUuidReputationCommunityidValuetypeidReputationtype(uuid, communityid, valuetypeid, reputationtype, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **uuid** | **String**|  | 
 **communityid** | **String**|  | 
 **valuetypeid** | **String**|  | 
 **reputationtype** | **String**|  | 

### Return type

**&#39;Number&#39;**

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="getPerson"></a>
# **getPerson**
> Person getPerson(uuid)

get Person

### Example
```javascript
var VerityReputation = require('verity_reputation');

var apiInstance = new VerityReputation.PersonApi();

var uuid = "uuid_example"; // String | multi-hash id of person record on the blockchain


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.getPerson(uuid, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **uuid** | **String**| multi-hash id of person record on the blockchain | 

### Return type

[**Person**](Person.md)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="getPersonContent"></a>
# **getPersonContent**
> [Content] getPersonContent(uuid, startDate, endDatepageNumber, pageSize, )

get Person Content

Get all the content this person has authored or co-authored

### Example
```javascript
var VerityReputation = require('verity_reputation');

var apiInstance = new VerityReputation.PersonApi();

var uuid = "uuid_example"; // String | multi-hash id of person record on the blockchain

var startDate = "startDate_example"; // String | 

var endDate = "endDate_example"; // String | 

var pageNumber = 56; // Number | starting page number. Must be > 0.

var pageSize = 56; // Number | number of records to return per page.


var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully. Returned data: ' + data);
  }
};
apiInstance.getPersonContent(uuid, startDate, endDatepageNumber, pageSize, , callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **uuid** | **String**| multi-hash id of person record on the blockchain | 
 **startDate** | **String**|  | 
 **endDate** | **String**|  | 
 **pageNumber** | **Number**| starting page number. Must be &gt; 0. | 
 **pageSize** | **Number**| number of records to return per page. | 

### Return type

[**[Content]**](Content.md)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: Not defined
 - **Accept**: application/json

<a name="updatePerson"></a>
# **updatePerson**
> updatePerson(opts)

update person

### Example
```javascript
var VerityReputation = require('verity_reputation');

var apiInstance = new VerityReputation.PersonApi();

var opts = { 
  'body': new VerityReputation.Person() // Person | 
};

var callback = function(error, data, response) {
  if (error) {
    console.error(error);
  } else {
    console.log('API called successfully.');
  }
};
apiInstance.updatePerson(opts, callback);
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **body** | [**Person**](Person.md)|  | [optional] 

### Return type

null (empty response body)

### Authorization

No authorization required

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

